users@glassfish.java.net

java.lang.NoSuchMethodError: org.omg.CosTransactions.OTSPolicy.value()S

From: <glassfish_at_javadesktop.org>
Date: Fri, 06 Jul 2007 12:36:13 PDT

Hi,
      While I was trying to do the unit test using TestNG, I got the following exception:

     java.lang.NoSuchMethodError: org.omg.CosTransactions.OTSPolicy.value()S

    during InitialContext.lookup

     I am not sure What I did wrong, please help.

    I have following the steps in FAQ for stand-alone java client and put the appserv-rt.jar and javaee.jar in the classpath. (The client and server on the same host).

    I used the InitialContext ctx = new InitialContext();

   Insteadof new InitialContext(Properties).

Anything else I should do ?

Thanks

Chester


--------------Here is the exception stack trace.


   [testng] java.lang.NoSuchMethodError: org.omg.CosTransactions.OTSPolicy.value()S
   [testng] at com.sun.jts.pi.InterceptorImpl.send_request(InterceptorImpl.java:234)
   [testng] at com.sun.corba.ee.impl.interceptors.InterceptorInvoker.invokeClientInterceptorStartingPoint(InterceptorInvoker.java:242)
   [testng] at com.sun.corba.ee.impl.interceptors.PIHandlerImpl.invokeClientPIStartingPoint(PIHandlerImpl.java:318)
   [testng] at com.sun.corba.ee.impl.protocol.CorbaClientRequestDispatcherImpl.beginRequest(CorbaClientRequestDispatcherImpl.java:251)
   [testng] at com.sun.corba.ee.impl.protocol.CorbaClientDelegateImpl.request(CorbaClientDelegateImpl.java:154)
   [testng] at com.sun.corba.ee.impl.protocol.CorbaClientDelegateImpl.is_a(CorbaClientDelegateImpl.java:294)
   [testng] at org.omg.CORBA.portable.ObjectImpl._is_a(ObjectImpl.java:112)
   [testng] at org.omg.CosNaming.NamingContextHelper.narrow(NamingContextHelper.java:69)
   [testng] at com.sun.enterprise.naming.SerialContext.narrowProvider(SerialContext.java:112)
   [testng] at com.sun.enterprise.naming.SerialContext.getProvider(SerialContext.java:166)
   [testng] at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:315)
   [testng] at javax.naming.InitialContext.lookup(InitialContext.java:351)
   [testng] at com.ascentmedia.ServiceLocator.getService(ServiceLocator.java:38)
[Message sent by forum member 'chesterxgchen123' (chesterxgchen123)]

http://forums.java.net/jive/thread.jspa?messageID=225540