File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and other Java EE Technologies and the fly likes Ejbs and Static variables Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Ejbs and Static variables" Watch "Ejbs and Static variables" New topic
Author

Ejbs and Static variables

Santhosh Kumar
Ranch Hand

Joined: Nov 07, 2000
Posts: 242
Hi,
I wanted to know,
1. Can we have static variables in Ejbs from J2EE point of view
2. Does it affect the performance?
Your help is very much appreciated.
Thanks,
Santhosh.
Chris Mathews
Ranch Hand

Joined: Jul 18, 2001
Posts: 2712
Static variables are allowed, however you should never write to them due to threading and clustering issues. It is good practice to make any static variables that you may use in your EJBs final also.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Ejbs and Static variables