Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problem while running client

Status
Not open for further replies.

nkmb

Programmer
May 10, 2006
33
US
Hi,

I am getting problem with Client.My client.java is compiling,by running the client,i am getting this error


Exception in thread "main" java.lang.UnsupportedClassVersionError: javax/securit
y/auth/callback/CallbackHandler (Unsupported major.minor version 48.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialCont
extFactory.java:131)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.InitialContext.<init>(Unknown Source)
at examples.HelloClient.main(HelloClient.java:25)

my HelloClient.java

<code>

package examples;

import javax.naming.*;
import javax.ejb.*;
import java.util.*;
import javax.rmi.*;
public class HelloClient {

public static void main(String[] args) throws Exception {
Hashtable h=null;
Context ctx=null;
try{


h = new Hashtable();
h.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");
h.put(Context.PROVIDER_URL, "t3://localhost:7001/");
ctx = new InitialContext(h);
// UNDU.......
}catch(Exception e)
{
e.printStackTrace();
}
Object obj = ctx.lookup("HelloHome");
HelloHome home = (HelloHome)
javax.rmi.PortableRemoteObject.narrow( obj, HelloHome.class);

Hello hello = home.create();

System.out.println(hello.hello());
hello.remove();
}
}

</code>

somebody please reply me,i am stuck with this since two days.

thanks,
bhavani.
 
Maybe your class is compiled against a JDK which vendor/version is different than the JRE used for execution.

Cheers,
Dian
 
Hi,

yes,That was my problem........it has been solved.
thanks for your reply.


thanks,
bhavani.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top