应该可以,没试过,你初始化Context的时候指定连接的服务器,如
Hashtable props = new Hashtable(); props.put(InitialContext.INITIAL_CONTEXT_FACTORY,
SystemProperty.getProperty(DefaultConfigDriver.
INITIAL_CONTEXT_FACTORY));
props.put(InitialContext.PROVIDER_URL,
SystemProperty.getProperty(DefaultConfigDriver.PROVIDER_URL)); //This establishes the security for authorization/authentication
props.put(InitialContext.SECURITY_PRINCIPAL,
SystemProperty.getProperty(DefaultConfigDriver.
SECURITY_PRINCIPAL));
props.put(InitialContext.SECURITY_CREDENTIALS,
SystemProperty.getProperty(DefaultConfigDriver.
SECURITY_CREDENTIALS)); context = new InitialContext(props);
Hashtable props = new Hashtable(); props.put(InitialContext.INITIAL_CONTEXT_FACTORY,
SystemProperty.getProperty(DefaultConfigDriver.
INITIAL_CONTEXT_FACTORY));
props.put(InitialContext.PROVIDER_URL,
SystemProperty.getProperty(DefaultConfigDriver.PROVIDER_URL)); //This establishes the security for authorization/authentication
props.put(InitialContext.SECURITY_PRINCIPAL,
SystemProperty.getProperty(DefaultConfigDriver.
SECURITY_PRINCIPAL));
props.put(InitialContext.SECURITY_CREDENTIALS,
SystemProperty.getProperty(DefaultConfigDriver.
SECURITY_CREDENTIALS)); context = new InitialContext(props);
解决方案 »
- Socket多流怎么同时传输问题 请教各位大侠 在线等
- WindowClosing事件的触发
- java 抛的数据库连接异常,求解?
- jboss.xml
- 关于java连接oracle的问题
- 事务(进程 ID 164)与另一个进程已被死锁在 lock 资源上,且该事务已被选作死锁牺牲(急啊!!!!!!!!)
- 有验证码的网站怎么自动抓取数据
- 大虾看看ant的build.xml文件里的一句
- 怎样解决用户在其他机器上登录会提示“用户已经在其他机器上登录”?
- 倾家荡产求解决方案,只是个概念问题,若您做过,就能拿到我所有的分,1000分
- 应用服务器+J2EE 和 Tomcat+Servlet 的优势和劣势是什么
- RMI调用端口问题,请教各位
继续。
是的。我也是这样设置的。
不知道为什么不行,好像是bea的问题。
现在后台抛
java.sql.SQLException: XA error: XAER_RMERR : A resource manager error has occured in the transaction branch start() failed on resource 'xaPool': XAER_RMERR : A resource manager error has occured in the transaction branch
oracle.jdbc.xa.OracleXAException
可是在同一个版本的weblogic上就没有什么问题啊。
郁闷啊。