0
A
回答
0
如果有人在將來想要一個答案,我用這個,我發現here:
Properties props = new Properties();
props.setProperty("java.naming.factory.initial", "com.sun.enterprise.naming.SerialInitContextFactory");
props.setProperty("java.naming.factory.url.pkgs", "com.sun.enterprise.naming");
props.setProperty("java.naming.factory.state", "com.sun.corba.ee.impl.presentation.rmi.JNDIStateFactoryImpl");
// Defaults to localhost.
props.setProperty("org.omg.CORBA.ORBInitialHost", "127.0.0.1");
// Defaults to 3700.
props.setProperty("org.omg.CORBA.ORBInitialPort", "3700");
InitialContext ic = new InitialContext(props);
RemoteBean beanInstance = (RemoteBean) ic.lookup("java:global/ExampleEJB/RemoteBean!com.example.RemoteBean");
相關問題
- 1. 如何將Web服務綁定到特定的glassfish端口?
- 2. 如何在GlassFish服務器
- 3. 如何指定服務器位置?
- 4. 如何指定Web服務器位置?
- 5. 如何確定64位服務器
- 6. GlassFish服務器日誌的位置
- 7. 如何運行服務於特定路徑的http服務器?
- 8. 如何搜索特定SRV服務的Windows DNS服務器樹?
- 9. DIV特定服務器
- 10. 如何將glassfish服務器的設置導出到另一個glassfish服務器?
- 11. WPF DI服務定位器
- 12. ZF2服務定位器
- 13. 如何將Web服務器重定向到特定的URL?
- 14. 如何在WCF服務中使用服務定位器
- 15. PHP CURL從特定服務器到另一個特定服務器不工作
- 16. 如何創建遠程GlassFish服務器
- 17. GlassFish服務器中的java.lang.UnsupportedClassVersionError?
- 18. 將列添加到MSSQL服務器中的特定位置
- 19. 限制Flash跨域訪問服務器上的特定位置
- 20. 獲取特定網站所在的服務器位置
- 21. 根據哪個服務器轉到特定的服務器?
- 22. 使用特定的emacs服務器
- 23. IE11:只有特定的服務器
- 24. SQL服務器 - 從特定的模式
- 25. SQL服務器 - 選擇特定的行
- 26. 非服務器特定的代理?
- 27. 服務,這聽服務定位服務
- 28. Guice風格的服務定位器
- 29. Swift中的服務定位器模式
- 30. 帶緩存的EJB服務定位器