Error casting context.lookup(…) returned object to ejb3 remote object interface
问题 I have an EJB stateless running under a JBoss server and a client under another JBoss server. In the client side, I am using the following code: final Properties initialContextProperties = new Properties(); initialContextProperties.put(Context.INITIAL_CONTEXT_FACTORY, "org.jboss.naming.remote.client.InitialContextFactory"); initialContextProperties.put(Context.PROVIDER_URL, "remote://127.0.0.1:8083"); initialContextProperties.setProperty(Context.URL_PKG_PREFIXES, "org.jboss.naming:org.jnp