• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Ron McLeod
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

Changing Servlets and EJBs during development without a redeploy

 
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I am using Weblogic 8.1 SP2 and I have deployed an Enterprise Application in an Exploded Archive Directory using the Split Development Directory Structure.
When I make a change to a Servlet and compile it in my IDE(Eclipse), the change is made automatically to the application, that is, all I have to do is to click "refresh" on the browser and I will see the change.
But when I make a change to an EJB, this change is not reflected in the application. I have to redeploy the application in order to see the change in the application.
For example:
I have a servlet called MyServlet and an EJB called MyEjb.
MyServlet's doGet() and doPost() methods lookup MyEjb and call MyEjb's sayHello() method which returns the String "hello". Then MyServlet prints on the web page the string returned from sayHello() and finally it prints the string "the end".
If I change MyServlet to print "THE END!!!" instead of "the end" then this change is reflected in the application without the need for a redeploy. But if I change MyEjb's sayHello() method to return "hi" instead of "hello" then I need to redeploy the application or else I cannot see the change in the actual application.
The question is: Is there anyway to make the change to an EJB be automatically made in the application just as it is done with the servlet?
 
Ranch Hand
Posts: 977
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

just place a file named REDEPLOY under the META-INF directory under the exploded directory, then when you want a redeploy just touch it to change it's timestamp, make sure your weblogic is configured to development mode and the server will automatically redeploy your entire application. You can see more on this at:
http://edocs.bea.com/wls/docs81/deployment/concepts.html#1007788
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic