javax.jms.JMSException: Failed to build body from content. Serializable class not available to broker. Reason: java.lang.ClassNotFoundException: Forbidden class foo.bar.classNmae! This class is not trusted to be serialized as ObjectMessage payload. Please take a look at http://activemq.apache.org/objectmessage.html for more information on how to configure trusted classes.. Message: ActiveMQObjectMessage {commandId = 3961, responseRequired = true, messageId = ID:DFRAPPQ20VW-58360-1475857780933-6671:1:566:1:1, originalDestination = null, originalTransactionId = null, producerId = ID:DFRAPPQ20VW-58360-1475857780933-6671:1:566:1, destination = queue://saveCorrespondenceQueue, transactionId = null, expiration = 0, timestamp = 1475869221862, arrival = 0, brokerInTime = 1475869221878, brokerOutTime = 1475869222018, correlationId = null, replyTo = null, persistent = true, type = null, priority = 4, groupID = null, groupSequence = 0, targetConsumerId = null, compressed = false, userID = null, content = org.apache.activemq.util.ByteSequence@e5dbb3b5, marshalledProperties = org.apache.activemq.util.ByteSequence@f9a0747e, dataStructure = null, redeliveryCounter = 3, size = 0, properties = {breadcrumbId=ID-DFRAPPQ20VW-58343-1475857776245-0-7}, readOnlyProperties = true, readOnlyBody = true, droppable = false, jmsXGroupFirstForConsumer = false}] org.apache.camel.RuntimeCamelException: Failed to extract body due to: javax.jms.JMSException: Failed to build body from content. Serializable class not available to broker. Reason: java.lang.ClassNotFoundException: Forbidden class foo.bar.classNmae! This class is not trusted to be serialized as ObjectMessage payload. Please take a look at http://activemq.apache.org/objectmessage.html for more information on how to configure trusted classes.. Message: ActiveMQObjectMessage {commandId = 3961, responseRequired = true, messageId = ID:DFRAPPQ20VW-58360-1475857780933-6671:1:566:1:1, originalDestination = null, originalTransactionId = null, producerId = ID:DFRAPPQ20VW-58360-1475857780933-6671:1:566:1, destination = queue://saveCorrespondenceQueue, transactionId = null, expiration = 0, timestamp = 1475869221862, arrival = 0, brokerInTime = 1475869221878, brokerOutTime = 1475869222018, correlationId = null, replyTo = null, persistent = true, type = null, priority = 4, groupID = null, groupSequence = 0, targetConsumerId = null, compressed = false, userID = null, content = org.apache.activemq.util.ByteSequence@e5dbb3b5, marshalledProperties = org.apache.activemq.util.ByteSequence@f9a0747e, dataStructure = null, redeliveryCounter = 3, size = 0, properties = {breadcrumbId=ID-DFRAPPQ20VW-58343-1475857776245-0-7}, readOnlyProperties = true, readOnlyBody = true, droppable = false, jmsXGroupFirstForConsumer = false}

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Stack Overflow by cnu
, 1 year ago
broker. Reason: java.lang.ClassNotFoundException: Forbidden class foo.bar.classNmae! This class is not trusted to be serialized as ObjectMessage payload. Please take a look at http://activemq.apache.org/objectmessage.html for more information on how to
via nabble.com by Unknown author, 2 years ago
Failed to build body from content. Serializable class not available to broker. Reason: java.lang.ClassNotFoundException. Message: ActiveMQObjectMessage {commandId = 19, responseRequired = true, messageId = ID:rsi-eng-newsham-56811-1289358131963-0
java.lang.ClassNotFoundException: Forbidden class foo.bar.classNmae! This class is not trusted to be serialized as ObjectMessage payload. Please take a look at http://activemq.apache.org/objectmessage.html for more information on how to configure trusted classes.
at org.apache.activemq.util.ClassLoadingAwareObjectInputStream.checkSecurity(ClassLoadingAwareObjectInputStream.java:112)
at org.apache.activemq.util.ClassLoadingAwareObjectInputStream.resolveClass(ClassLoadingAwareObjectInputStream.java:57)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1695)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1600)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1873)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1432)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:428)
at org.apache.camel.component.jms.JmsBinding.extractBodyFromJms(JmsBinding.java:135)
at org.apache.camel.impl.MessageSupport.getBody(MessageSupport.java:41)
at org.apache.camel.impl.DefaultUnitOfWork.(DefaultUnitOfWork.java:90)
at org.apache.camel.impl.DefaultUnitOfWork.(DefaultUnitOfWork.java:72)
at org.apache.camel.impl.DefaultUnitOfWorkFactory.createUnitOfWork(DefaultUnitOfWorkFactory.java:34)
at org.apache.camel.processor.CamelInternalProcessor$UnitOfWorkProcessorAdvice.createUnitOfWork(CamelInternalProcessor.java:663)
at org.apache.camel.processor.CamelInternalProcessor$UnitOfWorkProcessorAdvice.before(CamelInternalProcessor.java:631)
at org.apache.camel.processor.CamelInternalProcessor$UnitOfWorkProcessorAdvice.before(CamelInternalProcessor.java:608)
at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:138)
at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:109)
at org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:674)
at org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:634)
at org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:605)
at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:308)
at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:226)
at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1144)
at com.ibm.ws.asynchbeans.J2EEContext$RunProxy.run(J2EEContext.java:267)
at java.security.AccessController.doPrivileged(AccessController.java:300)
at javax.security.auth.Subject.doAs(Subject.java:494)
at com.ibm.websphere.security.auth.WSSubject.doAs(WSSubject.java:133)
at com.ibm.websphere.security.auth.WSSubject.doAs(WSSubject.java:91)
at com.ibm.ws.asynchbeans.J2EEContext$DoAsProxy.run(J2EEContext.java:338)
at java.security.AccessController.doPrivileged(AccessController.java:330)
at com.ibm.ws.asynchbeans.J2EEContext.run(J2EEContext.java:1174)
at com.ibm.ws.asynchbeans.WorkWithExecutionContextImpl.go(WorkWithExecutionContextImpl.java:199)
at com.ibm.ws.asynchbeans.CJWorkItemImpl.run(CJWorkItemImpl.java:236)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1881)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 3 months ago
Samebug visitor profile picture
Unknown user
Once, 3 months ago
Samebug visitor profile picture
Unknown user
Once, 3 months ago
Samebug visitor profile picture
Unknown user
Once, 3 months ago
Samebug visitor profile picture
Unknown user
Once, 3 months ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.