[jboss-jira] [JBoss JIRA] (WFLY-4308) Proxies created via ContextService.createContextualProxy(...) are not Serializable

Darran Lofthouse (JIRA) issues at jboss.org
Tue Aug 18 10:03:27 EDT 2015


    [ https://issues.jboss.org/browse/WFLY-4308?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13099452#comment-13099452 ] 

Darran Lofthouse commented on WFLY-4308:
----------------------------------------

Additional debug logging during serialization: -

{noformat}
org.jboss.as.server.moduleservice.ServiceModuleLoader
	- field (class "org.jboss.as.security.plugins.JNDIBasedSecurityManagement", name: "loader", type: "class org.jboss.modules.ModuleLoader")
	- object (class "org.jboss.as.security.plugins.JNDIBasedSecurityManagement", org.jboss.as.security.plugins.JNDIBasedSecurityManagement at 3ef0b8ca)
	- field (class "org.jboss.security.plugins.JBossSecurityContext", name: "iSecurityManagement", type: "interface org.jboss.security.ISecurityManagement")
	- object (class "org.jboss.security.plugins.JBossSecurityContext", [org.jboss.security.plugins.JBossSecurityContext()other)])
	- field (class "org.jboss.as.ee.concurrent.handle.SecurityContextHandleFactory$SecuritySetupContextHandle", name: "securityContext", type: "interface org.jboss.security.SecurityContext")
	- object (class "org.jboss.as.ee.concurrent.handle.SecurityContextHandleFactory$SecuritySetupContextHandle", org.jboss.as.ee.concurrent.handle.SecurityContextHandleFactory$SecuritySetupContextHandle at 38fa5f4a)
	- custom writeObject data (class "org.jboss.as.ee.concurrent.ConcurrentContext$ChainedSetupContextHandle")
	- object (class "org.jboss.as.ee.concurrent.ConcurrentContext$ChainedSetupContextHandle", org.jboss.as.ee.concurrent.ConcurrentContext$ChainedSetupContextHandle at 5135d8ac)
	- field (class "org.glassfish.enterprise.concurrent.internal.ContextProxyInvocationHandler", name: "capturedContextHandle", type: "interface org.glassfish.enterprise.concurrent.spi.ContextHandle")
	- object (class "org.glassfish.enterprise.concurrent.internal.ContextProxyInvocationHandler", org.glassfish.enterprise.concurrent.internal.ContextProxyInvocationHandler at 2019a5a1)
	- field (class "java.lang.reflect.Proxy", name: "h", type: "interface java.lang.reflect.InvocationHandler")
	- root object (class "com.sun.proxy.$Proxy49", org.jboss.as.test.integration.ee.concurrent.TestEJBRunnable at 6336c73b)
{noformat}


> Proxies created via ContextService.createContextualProxy(...) are not Serializable
> ----------------------------------------------------------------------------------
>
>                 Key: WFLY-4308
>                 URL: https://issues.jboss.org/browse/WFLY-4308
>             Project: WildFly
>          Issue Type: Bug
>          Components: EE
>    Affects Versions: 9.0.0.Alpha1
>            Reporter: Paul Ferraro
>            Assignee: Darran Lofthouse
>            Priority: Critical
>             Fix For: 10.0.0.Beta2
>
>
> Setting priority to critical since, I believe, this is a matter of compliance with the concurrency utilities specification.
> Section 3.3.4 of the specification states that:
> "All invocation handlers for the contextual proxy implementation must implement java.io.Serializable."
> While the invocation handler of the generated proxy does indeed implement Serializable, it contains a reference to org.jboss.as.server.moduleservice.ServiceModuleLoader (among others), which is not serializable, thus attempts to serialize the proxies generated via ContextService.createContextualProxy(...) via JBoss Marshalling throw a org.infinispan.commons.marshall.NotSerializableException: org.jboss.as.server.moduleservice.ServiceModuleLoader



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


More information about the jboss-jira mailing list