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 deploy the bean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "deploy the bean " Watch "deploy the bean " New topic
Author

deploy the bean

Soman Singh
Ranch Hand

Joined: Sep 02, 2003
Posts: 37
Hi All,
I have a form that has two fields.
I have the Entity Bean that gets the data for the fields.
Now if remove one of the fields from the form, where should I make the changes so that I need not deploy the bean again.
Thanks,
soman
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
I have a form that has two fields.
I have the Entity Bean that gets the data for the fields.
Now if remove one of the fields from the form, where should I make the changes so that I need not deploy the bean again.

How about not changing anything? Just don't use all the methods that the entity bean provides.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Soman Singh
Ranch Hand

Joined: Sep 02, 2003
Posts: 37
Hi Lasse,
The bean has not be deployed and thats fixed.
If its CMP Bean, then I can change the descriptor file by removing the <cmp-field> tag. What I mean is if I remove those tags from this file the bean shall still call the fields from the create(). Like I am not sure about the answer.

But if its is a BMP then I can comment or remove the ejbCreate method. But this has to be compiled and re-deployed again which I don't want.
So how should I proceed. I guess I am clear .. If not I shall explain again.
Thanks ..
Soman Singh
Ranch Hand

Joined: Sep 02, 2003
Posts: 37
Ok something more ...
In the first instance I created the Bean and its has the ejbCreate().
Now if I remove a field the how should I do it ?? wether its bmp or cmp.
So in case, any changes made to the bean shall need a compilation and re-deplyment.
So my point was there should be no re-deployment.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
If you remove the cmp-field element for a field from your deployment descriptor, it is very likely that your appserver won't generate the concrete methods for you -- leading to a fatal error regarding your build process.
I can see two options:
1) Don't change anything but tell the "client" not to use a particular method
2) Change everything as even a partial (code) change would require redeployment
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: deploy the bean