• Post Reply Bookmark Topic Watch Topic
  • New Topic

NotSerializableException when i use rmiregistry  RSS feed

 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am working with Blaze Rule Engine and reading the binary rules file from the service code that is written in Java. I have to use some classes (located in jars) which supports my application and all the classes are serialized.

after deploying my application as ejb in Oracle Apps, i can use 'rmiregistry' for generating the response.

so, my application is working perfectly fine without rmiregistry and also giving the proper response........ but when i am using the rmiregistry its giving the following error




Ofcouse i have serialized all the classes in jarfiles...... even then i am getting error when i use 'rmiregistry'

Please suggest me some solution.........
 
Joe Ess
Bartender
Posts: 9406
12
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
public class NotSerializableException
extends ObjectStreamException

Thrown when an instance is required to have a Serializable interface. The serialization runtime or the class of the instance can throw this exception. The argument should be the name of the class.

NotSerializableException

This exception has nothing to do with jar files. The class you are trying to serialize does not implement Serializable
 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes, i have implemented Serializable interface to all the dependent classes in the Application. i dont know why the blaze rule engine was not able to serialize the instances of my classes when i use the rmiregistry.

And i also tested some samples applications on Blaze advisor Rule engine with rmiregistry.... by giving simple string and not using any dependent classes, this worked perfectly fine...... but when i am using some any classes its giving the above error which i posted last time........

plese give some suggestion,...........
 
Joe Ess
Bartender
Posts: 9406
12
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is an unusual class name:

Perhaps the rules engine is creating classes on the fly. Have you tried contacting support?
 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks to all for helping me............ I especially thanks to Joe Ess for suggestions.........

I got the solution for the problem by precompiling the project from the console using all the dependent jar files, .server and .dmanager files(these files are generated by blaze rule engine)

this is the precompile statement

java -mx256m com.blazesoft.server.deploy.tools.NdAdvisorProjectCompiler -deploymentManager "./TestProjectServer.dmanager" -server "./TestProject.server"
[ April 29, 2008: Message edited by: pavan kumar seeram ]
 
Prakash Subramanian
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I do not understand the pre-compile portion? What does it mean?
 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Precompiling means... we are compling the project through the console using .dmanager file and .server file, so that blaze rule engine will create the .adb file and _ser.dmanger for the Repository mentioned in the .dmanger file.

this is the precompile statement we have to execute on console. Here "TestProjectServer.dmanager" and "TestProject.server" are .dmanager and .server files for "TestProject". These files are generated during deployment of project

java -mx256m com.blazesoft.server.deploy.tools.NdAdvisorProjectCompiler -deploymentManager "./TestProjectServer.dmanager" -server "./TestProject.server"

If you have any more doubts regarding Blaze rule engine.... let me know....
 
arvind Pazare
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi pavan kumar seeram

I am working on auto deployment of repository to Jboss 4.0.2.
Can you give me some idea or steps how it works. I am using Blaze Advisor 6.1.

Thankx
Arvind
 
arvind Pazare
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i am getting error while executing ant test do you hav any idea
Exception in thread "main" java.lang.NoClassDefFoundError: org/jboss/logging/Logger
thankx
 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Error java.lang.NoClassDefFoundError: org/jboss/logging/Logger indicates the jar file is missing with package name org.jboss.logging.Logger in your .ear file, please place this jar file and try to deploy again. If still this doesnt work try to include the classpath in MANIFEST.MF as Class-Path: log4j-1.2.7.jar
you can see you manifest file at META-INF/MANIFEST.MF in your .ear file
 
arvind Pazare
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thankx pravin,

log4j-1.2.7.jar was not there in setting environment.. i added & its working... Now I am able to hit deployed rule services in JBoss from command prompt (as per Blaze Advisor 6.1 doc says "ant test")....
My biggest challenge is to access deployed .jar rule service using webservice is it possible.

(I am implementing deployment manager in jboss for Blaze advisor 6.1)

Thnakx

Arvind
 
pavan kumar seeram
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That fine......... Arvind........

Yes, you can access your rule service using webservice tooo and that is pretty simple also....... Suppose your Rule Service was deployed as EJB, then you can directly expose your invoking function in EJB as webservice and call your Ruleservice.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!