"mike_ap" wrote :
|
|
|
| | context = new InitialContext();
| | LogFileManagerRemote beanRemote = (LogFileManagerRemote)
context.lookup(LogFileManager.RemoteJNDIName);
| |
| | MyLogFile file = new MyLogFile("newfile.log", 12345);
| | beanRemote.saveMyLogFile(file);
| | System.out.println(file.getId());
| |
|
|
When you are using a remote bean, the parameters are passed by value. So any changes to
the "file" entity that you are passing will not be reflected in the method that
calls the bean. So at your client, you should use the object returned by your bean. That
object will have the id set:
MyLogFile savedFile = beanRemote.saveMyLogFile(file);
| System.out.println(savedFile.getId());
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4184211#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...