Flex error...Encoding of AMF message failed. java.lang.ClassNotFoundException
I noticed others were having a issues with Flex and ClassNotFoundExceptions.... and today I started having the same thing.... so I thought I would share my solution.
In my case I had just upgraded to new generators (New Hardware, Win7 64-bit, new JDK, etc)... The scripts were working on the old generators (WinXP), but failing on new generators. Turns out it was not due to hardware, os , or jdk... it was something else....
I decided I would use the "Run as a Service" for the LR Agent process on the new generators. This helped me by not requiring me to login to each generator after a reboot (to get the LR Agent loaded) which was very time consuming as our pool increased.
The problem this caused was that my .jar files (Runtime Settings -> Flex - > Enternalizable Objects were located on a network share. Since the LR Agent was now being launched as a Service, there was NO drive mapped to the network share. In my runtime settings I was loading the .jars from X:\jars\. The X: drive was mapped on each generator. Strange things was even after I logged into the generator and had the X: drive mapped, the service still does not see it.
The solution... change from a mapped drive letter to a UNC path. ex... \\myserver\jars\ for each Externalizable Object.
Hope this saves somebody out there the few hours it took me to track this down....
Tags for this Thread