"gduan2000" wrote : similar issue
|
| trying to serialize an Object from ejb3 layer to web layer (servlet).
|
| did not happend on 4.0.3sp1 and before (EJBRC3).
|
| ------------------------------
|
| type Exception report
|
| message
|
| description The server encountered an internal error () that prevented it
from fulfilling this request.
|
| exception
|
| java.lang.ClassCastException: org.jboss.ejb3.stateless.StatelessBeanContext
|
org.jboss.ejb3.injection.ExtendedPersistenceContextInjector.inject(ExtendedPersistenceContextInjector.java:57)
| org.jboss.ejb3.injection.ExtendedPersistenceContextInjector.
|
Well, I found the fix for my issue. The class I was trying to serialize had a
field like this:
private SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yyyy hh:mm:ss aa");
It was OK in 4.0.3SP1, but since I switch to EJB3.0RC5, It stopped working. I
spend hours searching and testing. Eventually I found the fix: just change it
to static final.
private static final SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yyyy
hh:mm:ss aa");
I don't know if this is a JBoss issue or what it is supposed to be. Can someone
explain?
Hope this might help someone who is searching for an answer...
g
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3924349#3924349
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3924349
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user