Ordinary hut

          人間一福地,勝似天仙宮
          posts - 61, comments - 50, trackbacks - 0, articles - 1

          weblogic集群中獲取jndi的方式

          Posted on 2010-01-20 21:25 landor 閱讀(1076) 評論(0)  編輯  收藏 所屬分類: weblogic
          在非集群中,也就是單server的時候采用的是如下方式:
          Hashtable ht = new Hashtable();
          ht.put(Context.INITIAL_CONTEXT_FACTORY,
          "weblogic.jndi.WLInitialContextFactory");
          ht.put(Context.PROVIDER_URL,
          "t3://localhost:7001");
          ......
          但是在集群環境中,如何配置?
          參照weblogic文檔
          http://download.oracle.com/docs/cd/E15051_01/wls/docs103/jndi/jndi.html#wp467605
          知道可以這么設置
          # The following example specifies a list of WebLogic Servers using the same port:
          ht.put(Context.PROVIDER_URL,
          "t3://acme1,acme2,acme3:7001");

          All the WebLogic Servers listen on the port specified at the end of the URL.
          # The following example specifies a list of WebLogic Servers using the different ports:
          ht.put(Context.PROVIDER_URL,
          "t3://node1:7001,node2:7002,node3:7003");
          端口相同的話,可以省略端口,放到最后面寫,端口不同就都寫上
          這樣weblogic會自動尋找相應的jndi

          主站蜘蛛池模板: 临海市| 开封市| 扬州市| 巴马| 喀喇沁旗| 荥经县| 乃东县| 宁明县| 开原市| 玉屏| 石城县| 突泉县| 封开县| 元江| 农安县| 娄底市| 连江县| 九龙县| 富宁县| 多伦县| 海城市| 肇东市| 四平市| 平山县| 涞水县| 洪泽县| 海城市| 涞源县| 镇康县| 陆丰市| 将乐县| 长岭县| 米脂县| 左贡县| 肇源县| 蒙自县| 弋阳县| 沾益县| 浦东新区| 右玉县| 江津市|