Oh the joys of the OC4J Classloader. It's been a long time since I used OC4J and Flex, but I do remember it being an adventure. None-the-less I'd suggest you try LCDS 2.5 and see if we have dealt with the problem. You can find LCDS 2.5 at the bottom of this page: http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=kb401825
If that doesn't help I'll see if I can get someone from engineering to help figure this out. Sorry I don't have a better answer for you. -James From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of mattjshannon Sent: Friday, May 04, 2007 9:35 AM To: [email protected] Subject: [flexcoders] Classloader issue using Flex Data Services with OC4J 10.1.3 Hi, As a learning exercise, I have tried to port James Ward's WeBudget RIA Flex 1.5 Cairngorm 0.99 EJB 3 application across to Flex 2.0.1 with FDS using Caigrngorm 2.2 running on Oracle Containers for Java 10.1.3 (deployed as an enterprise application / EAR) http://www.jamesward.org/wordpress/2005/06/26/10/ I also have followed FDS setup instructions for OC4J per the following link :- http://www.adobe.com/support/documentation/en/flex/2/install.html#oc4j I've got the application partially firing with FDS able to correctly retrieve the entity beans results (containing both simple string/date and complex attributes such as java.util.collections attributes) from the remoted ejb session bean services and instantiate local client actionscript view object representations accordingly. What I'm experiencing however, is when trying to push actionscript view object's back to the server which contain complex array types as parameters to methods of the remoted EJB session beans, a service fault occurs stating the flex.messaging.io.ArrayCollection class was not found. What I found was moving all the flex web app's java delegate classes along with ALL flex* and common* libraries out of the applications WEB-INF/lib folder to OC4J's j2ee/home/applib folder fixed the issue. Presumably as they are now picked up as global libraries and available to all J2EE application components deployed to the container (must be running in a parent classloader to the individual applications deployed). The exact error I received is shown at the bottom of this message. Has anyone seen a similar classloading issue on other application servers for FDS projects? What component on the server is actually trying to perform the class.forName below? Where is it running? Presumably it is not a component packaged in the web application of the EAR I deployed to the server - otherwise it should have picked up the libraries under WEB-INF/lib cheers Matt. --------------------------------------------- 07/05/04 23:46:31 [Flex] Serializing AMF/HTTP response Version: 3 (Message #0 targetURI=/5/onStatus, responseURI=) (Typed Object #0 'flex.messaging.messages.ErrorMessage') rootCause = (Typed Object #1 'javax.ejb.EJBException') causedByException = (Typed Object #2 'oracle.classloader.util.AnnotatedClassNotFoundException') localizedMessage = " Missing class: flex.messaging.io.ArrayCollection Dependent class: com.evermind.io.ClassLoaderObjectInputStream Loader: oc4j:10.1.3 Code-Source: /C:/oc4j101320/j2ee/home/lib/oc4j- internal.jar Configuration: <code-source> in META-INF/boot.xml in C:\oc4j101320\j2ee\home\oc4j.jar This load was initiated at webudget.root:0.0.0 using the Class.forName () method. The missing class is available from the following locations: 1. Code- Source: /C:/oc4j101320/j2ee/home/applications/webudget/webudgetWEB/WEB -INF/lib/flex-messaging.jar (from WEB-INF/lib/ directory in C:\oc4j101320\j2ee\home\applications\webudget\webudget WEB\WEB-INF\lib) This code-source is available in loader webudget.web.webudgetWEB:0.0.0. This is the current thread's context loader, and it appears that Class.forName() was used to load the dependent class . If a loader was not explicitly passed to Class.forName(), try passing the result of calling Thread.currentThread ().getContextClassLoader(). " annotation = (Typed Object #3 'oracle.classloader.util.MissingClass') exception = null message = " Missing class: flex.messaging.io.ArrayCollection Dependent class: com.evermind.io.ClassLoaderObjectInputStream Loader: oc4j:10.1.3 Code-Source: /C:/oc4j101320/j2ee/home/lib/oc4j- internal.jar Configuration: <code-source> in META-INF/boot.xml in C:\oc4j101320\j2ee\home\oc4j.jar This load was initiated at webudget.root:0.0.0 using the Class.forName () method. The missing class is available from the following locations: 1. Code- Source: /C:/oc4j101320/j2ee/home/applications/webudget/webudgetWEB/WEB -INF/lib/flex-messaging.jar (from WEB-INF/lib/ directory in C:\oc4j101320\j2ee\home\applications\webudget\webudget WEB\WEB-INF\lib) This code-source is available in loader webudget.web.webudgetWEB:0.0.0. This is the current thread's context loader, and it appears that Class.forName() was used to load the dependent class . If a loader was not explicitly passed to Class.forName(), try passing the result of calling Thread.currentThread ().getContextClassLoader(). " message = "Error (de-)serializing object, class not found: Missing class: flex.messaging.io.ArrayCollection Dependent class: com.evermind.io.ClassLoaderObjectInputStream Loader: oc4j:10.1.3 Code-Source: /C:/oc4j101320/j2ee/home/lib/oc4j- internal.jar Configuration: <code-source> in META-INF/boot.xml in C:\oc4j101320\j2ee\home\oc4j.jar This load was initiated at webudget.root:0.0.0 using the Class.forName () method. The missing class is available from the following locations: 1. Code- Source: /C:/oc4j101320/j2ee/home/applications/webudget/webudgetWEB/WEB -INF/lib/flex-messaging.jar (from WEB-INF/lib/ directory in C:\oc4j101320\j2ee\home\applications\webudget\webudget WEB\WEB-INF\lib) This code-source is available in loader webudget.web.webudgetWEB:0.0.0. This is the current thread's context loader, and it appears that Class.forName() was used to load the dependent class . If a loader was not explicitly passed to Class.forName(), try passing the result of calling Thread.currentThread ().getContextClassLoader(). ; nested exception is: oracle.classloader.util.AnnotatedClassNotFoundException: Missing class: flex.messaging.io.ArrayCollection Dependent class: com.evermind.io.ClassLoaderObjectInputStream Loader: oc4j:10.1.3 Code-Source: /C:/oc4j101320/j2ee/home/lib/oc4j- internal.jar Configuration: <code-source> in META-INF/boot.xml in C:\oc4j101320\j2ee\home\oc4j.jar This load was initiated at webudget.root:0.0.0 using the Class.forName () method. cause = null destination = "categoryFlexDelegateImpl" headers = (Object #4) correlationId = "42CD3AEC-EB9A-5E76-0DB3-5757810A882A" faultString = "javax.ejb.EJBException : Error (de-)serializing object, class not found: Missing class: flex.messaging.io.ArrayCollection Dependent class: com.evermind.io.ClassLoaderObjectInputStream Loader: oc4j:10.1.3 Code-Source: /C:/oc4j101320/j2ee/home/lib/oc4j- internal.jar Configuration: <code-source> in META-INF/boot.xml in C:\oc4j101320\j2ee\home\oc4j.jar This load was initiated at webudget.root:0.0.0 using the Class.forName () method.

