0 Replies Latest reply: Jan 4, 2012 9:27 AM by 908923 RSS

    Environment specifc value using JNDI

    908923
      How can I add an Environment specific 'String' variable to the iPlanet/Sun Web server and access it from the application? In the case of tomcat server, we had the following property in the context xml

      <Environment name="instanceNum" value="100100"
      type="java.lang.String" override="false"/>

      and used the following code in the application

      Context initCtx = new InitialContext();
      Context envCtx = (Context) initCtx.lookup("java:comp/env");
      envCtx.lookup("instanceNum");

      Thank you