{"action":"created","issue":{"url":"https://api.github.com/repos/payara/Payara/issues/1035","repository_url":"https://api.github.com/repos/payara/Payara","labels_url":"https://api.github.com/repos/payara/Payara/issues/1035/labels{/name}","comments_url":"https://api.github.com/repos/payara/Payara/issues/1035/comments","events_url":"https://api.github.com/repos/payara/Payara/issues/1035/events","html_url":"https://github.com/payara/Payara/issues/1035","id":171124741,"number":1035,"title":"java.lang.ClassCastException: Object is not of remote type java.rmi.Remote","user":{"login":"Quix0r","id":470798,"avatar_url":"https://avatars.githubusercontent.com/u/470798?v=3","gravatar_id":"","url":"https://api.github.com/users/Quix0r","html_url":"https://github.com/Quix0r","followers_url":"https://api.github.com/users/Quix0r/followers","following_url":"https://api.github.com/users/Quix0r/following{/other_user}","gists_url":"https://api.github.com/users/Quix0r/gists{/gist_id}","starred_url":"https://api.github.com/users/Quix0r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Quix0r/subscriptions","organizations_url":"https://api.github.com/users/Quix0r/orgs","repos_url":"https://api.github.com/users/Quix0r/repos","events_url":"https://api.github.com/users/Quix0r/events{/privacy}","received_events_url":"https://api.github.com/users/Quix0r/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/payara/Payara/labels/0:Triaged","name":"0:Triaged","color":"0052cc"},{"url":"https://api.github.com/repos/payara/Payara/labels/c:PossibleBug","name":"c:PossibleBug","color":"bfd4f2"},{"url":"https://api.github.com/repos/payara/Payara/labels/Test%20Case%20Required","name":"Test Case Required","color":"006b75"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-08-15T07:57:55Z","updated_at":"2016-08-16T10:12:38Z","closed_at":null,"body":"````\r\nWarnung:   StandardWrapperValve[Faces Servlet]: Servlet.service() for servlet Faces Servlet threw exception\r\njava.lang.ClassCastException: Object is not of remote type java.rmi.Remote\r\n\tat com.sun.corba.ee.impl.javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:254)\r\n\tat javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:150)\r\n\tat com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl$12.read(DynamicMethodMarshallerImpl.java:352)\r\n\tat com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl.readResult(DynamicMethodMarshallerImpl.java:482)\r\n\tat com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:201)\r\n\tat com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:150)\r\n\tat com.sun.corba.ee.impl.presentation.rmi.codegen.CodegenStubBase.invoke(CodegenStubBase.java:226)\r\n\tat com.sun.ejb.codegen._GenericEJBHome_Generated_DynamicStub.create(com/sun/ejb/codegen/_GenericEJBHome_Generated_DynamicStub.java)\r\n\tat sun.reflect.GeneratedMethodAccessor446.invoke(Unknown Source)\r\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\r\n\tat java.lang.reflect.Method.invoke(Method.java:498)\r\n\tat com.sun.ejb.EJBUtils.lookupRemote30BusinessObject(EJBUtils.java:421)\r\n\tat com.sun.ejb.containers.RemoteBusinessObjectFactory.getObjectInstance(RemoteBusinessObjectFactory.java:75)\r\n\tat javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:321)\r\n\tat com.sun.enterprise.naming.impl.SerialContext.getObjectInstance(SerialContext.java:527)\r\n\tat com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:487)\r\n\tat com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:438)\r\n\tat javax.naming.InitialContext.lookup(InitialContext.java:417)\r\n\tat javax.naming.InitialContext.lookup(InitialContext.java:417)\r\n\tat com.company.project.converter.country.ProjectCountryConverter.<init>(LandingCountryConverter.java:66)\r\n\tat sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)\r\n\tat sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)\r\n\tat sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)\r\n\tat java.lang.reflect.Constructor.newInstance(Constructor.java:423)\r\n\tat java.lang.Class.newInstance(Class.java:442)\r\n\tat com.sun.faces.application.ApplicationImpl.newThing(ApplicationImpl.java:1729)\r\n\tat com.sun.faces.application.ApplicationImpl.createConverter(ApplicationImpl.java:1332)\r\n\tat javax.faces.application.ApplicationWrapper.createConverter(ApplicationWrapper.java:393)\r\n\tat com.sun.faces.facelets.tag.jsf.ConverterTagHandlerDelegateImpl.createConverter(ConverterTagHandlerDelegateImpl.java:158)\r\n\tat com.sun.faces.facelets.tag.jsf.ConverterTagHandlerDelegateImpl.applyAttachedObject(ConverterTagHandlerDelegateImpl.java:128)\r\n\tat javax.faces.view.facelets.FaceletsAttachedObjectHandler.applyAttachedObject(FaceletsAttachedObjectHandler.java:98)\r\n\tat com.sun.faces.facelets.tag.jsf.ConverterTagHandlerDelegateImpl.apply(ConverterTagHandlerDelegateImpl.java:77)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)\r\n\tat com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:202)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:194)\r\n\tat com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)\r\n\tat com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:87)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:312)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:371)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:350)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:199)\r\n\tat com.sun.faces.facelets.tag.ui.IncludeHandler.apply(IncludeHandler.java:124)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)\r\n\tat com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:202)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)\r\n\tat com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:194)\r\n\tat com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)\r\n\tat com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:87)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:312)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:371)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:350)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:199)\r\n\tat com.sun.faces.facelets.tag.ui.IncludeHandler.apply(IncludeHandler.java:124)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)\r\n\tat com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:202)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat com.sun.faces.facelets.tag.ui.DefineHandler.applyDefinition(DefineHandler.java:106)\r\n\tat com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:206)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext$TemplateManager.apply(DefaultFaceletContext.java:395)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext.includeDefinition(DefaultFaceletContext.java:366)\r\n\tat com.sun.faces.facelets.tag.ui.InsertHandler.apply(InsertHandler.java:111)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)\r\n\tat com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:202)\r\n\tat javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat com.sun.faces.facelets.tag.jsf.core.ViewHandler.apply(ViewHandler.java:225)\r\n\tat javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:95)\r\n\tat com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)\r\n\tat com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:87)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:312)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:371)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:350)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:199)\r\n\tat com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:174)\r\n\tat com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)\r\n\tat com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:87)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:312)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:371)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:350)\r\n\tat com.sun.faces.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:199)\r\n\tat com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:174)\r\n\tat com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)\r\n\tat com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:87)\r\n\tat com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:161)\r\n\tat com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:1006)\r\n\tat com.sun.faces.application.view.FaceletViewHandlingStrategy.restoreView(FaceletViewHandlingStrategy.java:585)\r\n\tat com.sun.faces.application.view.MultiViewHandler.restoreView(MultiViewHandler.java:151)\r\n\tat javax.faces.application.ViewHandlerWrapper.restoreView(ViewHandlerWrapper.java:353)\r\n\tat com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:199)\r\n\tat com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)\r\n\tat com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:123)\r\n\tat com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:198)\r\n\tat javax.faces.webapp.FacesServlet.service(FacesServlet.java:658)\r\n\tat org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1682)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:344)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)\r\n\tat org.apache.logging.log4j.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:71)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:256)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)\r\n\tat org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:316)\r\n\tat org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:160)\r\n\tat org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:734)\r\n\tat org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:673)\r\n\tat com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:99)\r\n\tat org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:174)\r\n\tat org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:416)\r\n\tat org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:283)\r\n\tat com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:459)\r\n\tat com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:167)\r\n\tat org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:206)\r\n\tat org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:180)\r\n\tat org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:235)\r\n\tat org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)\r\n\tat org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:284)\r\n\tat org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:201)\r\n\tat org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:133)\r\n\tat org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:112)\r\n\tat org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)\r\n\tat org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:526)\r\n\tat org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:112)\r\n\tat org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:117)\r\n\tat org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:56)\r\n\tat org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:137)\r\n\tat org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:591)\r\n\tat org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:571)\r\n\tat java.lang.Thread.run(Thread.java:745)\r\n````\r\nThis happens sporalic but still to much that it became anoying. It seems like that the container gets \"confused\" with all the remote EJB calls, managed bean injections and JMS queues.\r\n\r\nThe line 66 in ProjectCountryConverter says:\r\n````\r\nthis.countryBean = (CountrySingletonBeanRemote) context.lookup(\"java:global/project-ejb/country!foo.something.jcountry.data.CountrySingletonBeanRemote\"); //NOI18N\r\n````\r\n\r\n**CountrySingletonBeanRemote** is a remote interface annotated with **javax.ejb.Remote;** and not **java.rmi.Remote**.\r\n\r\nTh converter is annotated with **@FacesConverter (value = \"CountryConverter\")** which is **javax.faces.convert.FacesConverter** It may not be easy to reproduce as I said, it looks like Payara (I first discovered the bug in Glassfish so it is a legacy bug) gets confused somehow.\r\n\r\nAfter a restart, all is fine until Payara/Glassfish gets confused again."},"comment":{"url":"https://api.github.com/repos/payara/Payara/issues/comments/240061943","html_url":"https://github.com/payara/Payara/issues/1035#issuecomment-240061943","issue_url":"https://api.github.com/repos/payara/Payara/issues/1035","id":240061943,"user":{"login":"Quix0r","id":470798,"avatar_url":"https://avatars.githubusercontent.com/u/470798?v=3","gravatar_id":"","url":"https://api.github.com/users/Quix0r","html_url":"https://github.com/Quix0r","followers_url":"https://api.github.com/users/Quix0r/followers","following_url":"https://api.github.com/users/Quix0r/following{/other_user}","gists_url":"https://api.github.com/users/Quix0r/gists{/gist_id}","starred_url":"https://api.github.com/users/Quix0r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Quix0r/subscriptions","organizations_url":"https://api.github.com/users/Quix0r/orgs","repos_url":"https://api.github.com/users/Quix0r/repos","events_url":"https://api.github.com/users/Quix0r/events{/privacy}","received_events_url":"https://api.github.com/users/Quix0r/received_events","type":"User","site_admin":false},"created_at":"2016-08-16T10:12:38Z","updated_at":"2016-08-16T10:12:38Z","body":"I currently only deploy one WAR and two EJBs (a local logger EJB and a \"regular\" EJB project for all my data."}}
{"actor":{"display_login":"Quix0r"}}