File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Object Relational Mapping and the fly likes EJB 3 javax.naming.Communication Exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Reply locked New topic

EJB 3 javax.naming.Communication Exception

Rajesh Rathod

Joined: Aug 01, 2007
Posts: 24
Hi, I am trying to access a remote stateless bean from a standalone client. I am using JBOSS application server.But I am getting the following exception:

javax.naming.CommunicationException [Root exception is org.jboss.ejb3.stateless.StatelessRemoteProxy; local class incompatible: stream classdesc serialVersionUID = 2583299153931800023, local class serialVersionUID = -9097306519795868]
at org.jnp.interfaces.NamingContext.lookup(
at org.jnp.interfaces.NamingContext.lookup(
at javax.naming.InitialContext.lookup(
at com.ejb.bean.FirstEJB3TutorialClient.main(

where is my client application running on a separate machine.

The code snippets for the various classes used are as follows:

BookTestBeanRemote interface:
public interface BookTestBeanRemote {
public void testBook();
public void testCustomer();
public void testRelation();

BookTestBean class:


public class BookTestBean implements BookTestBeanRemote {


EntityManager em;

FirstEJB3TutorialClient class:

public class FirstEJB3TutorialClient {
public static void main(String[] args) {
try {
Properties properties = new Properties();
"org.jboss.naming rg.jnp.interfaces");
properties.put(Context.PROVIDER_URL, "");
Context context = new InitialContext(properties);
BookTestBeanRemote beanRemote = (BookTestBeanRemote) context


where is the IP address of the server where JBOSS server is running.

Can someone please help me out??


Rajesh Rathod<br />SCJP 1.4
Jaikiran Pai

Joined: Jul 20, 2005
Posts: 10441

Let's continue the discussion in your other thread

[My Blog] [JavaRanch Journal]
Mark Spritzler

Joined: Feb 05, 2001
Posts: 17276

Please do not duplicate post. The EJB3 forum is the more appropriate forum, this forum is for Object Relation Mapping tools only, which does cover JPA.


Perfect World Programming, LLC - iOS Apps
How to Ask Questions the Smart Way FAQ
I agree. Here's the link:
subject: EJB 3 javax.naming.Communication Exception
It's not a secret anymore!