WebLogic 10.3 and IntelliJ IDEA 8.1.4

Hey there,

I'm trying to use the WebLogic support in IDEA 8.1.4. It's a regular web-application with a maven2 build. I've got things mostly working to the point that it's possible to build, deploy and debug the application (including JSPs) from within IDEA. I have some remaining issues that I'm looking for feedback on, however:

First off, I've been trying both local and remote WebLogic run configs, and I can't really see any advantage to using Local over Remote (remote but running on localhost still), aside from giving IDEA the ability to start and stop the server instance. I was hoping a local config would use an exploded deployment and enable the use of FastSwap or at least reload JSPs without a full redeploy required. However, I can't see that deploying a war or an exploded dir made any difference in a local config. Am I simply doing it wrong?

- I can't seem to get my project set up in such a way that I can simply save JSPs, JavaScript files and so on and then reload the page in my browser to test changes. At present, I must do a full redeploy, which takes longer and also wipes session data so that I have to redo wizard steps and such to get back to the point I was testing. Is it possible to set IDEA up so that I can just save my JSP and reload the page in browser?
- Less important than the first point: I have not been able to find a setup that enables me to utilize WebLogic 10.3's FastSwap feature (basically limited and BEA-proprietary JavaRebel that reloads modified classes in WEB-INF/classes for an exploded application without the need to redeploy). Is it possible to get this working from within IDEA? The point about JSPs is more important to me as classes are easier to test outside the container with unit tests and whatnot, and there's always the real JavaRebel as an alternative, but it would be nice to have it working since it's there..


Lastly, some minor annoyances I've currently been more or less able to work around:

  1. I get the following warning: "Cannot debug Web facet 'Web': debugging is off. Clicking the FIX button injects an element into weblogic.xml that makes subsequent redeploys fail because of schema validation. A search of this list seems to indicate that this check may be based on this element being needed for JSP debugging in WLS8. This no longer seems to be the case as my weblogic.xml does not contain this element but JSP debugging is  actually working. Not quite sure what enables it now - possibly running the server in devmode is sufficient.
  2. When I launch the WebLogic run config and the app redeploys, the Web Facet being deployed is displayed with an orange exclamation mark under IDEA's Console-tab. The message is "Error during facet deployment, see error-log for details". However, deployment seems to have gone fine. The final entry of the serverlog is typically something like "<BEA-149074> <Successfully completed deployment task: [Deployer:149026]deploy application myAppWeb on wlServer.>.
  3. A third issue is that the weblogic integration seems fairly fragile. I'm not sure if this is on the IDEA or the WebLogic side of things (I've been having simular issues in WebLogic Workshop), but I frequently run into issues where I have to manually clean up and restart the server with the WebLogic administration console due to a failed deployment that simply won't go away. A reasonably reproducible way to trigger such a "locked state" from IDEA seems to be clicking "Deploy all" under Console again while another deploy is running. It will basically cause this:
    1. The first time: "com.intellij.javaee.weblogic.runDebug.weblogicServerInstances.version9.mbeansModel.JMWrappedException: javax.management.MBeanException: MBean invoke failed: weblogic.management.provider.EditSaveChangesFailedException: Can not save changes while prepare changes are still in progress".
    2. So that was expected as the first redeploy is already running (and will also complete successfully). This is where the troubles begin however. From now on, all attempts to redeploy will fail with the following error until I manually clean up using the WebLogic admin console: com.intellij.javaee.weblogic.runDebug.weblogicServerInstances.version9.mbeansModel.JMWrappedException: javax.management.MBeanException: MBean invoke failed: weblogic.management.ManagementException: [Deployer:149001]No application named 'myAppWeb' exists for operation undeploy


The strange thing about #2 is that the deployment status gets a green "OK", as opposed to the orange exclamation mark/warning when it was actually successful

2 comments
Comment actions Permalink

Hello,

Hey there,

I'm trying to use the WebLogic support in IDEA 8.1.4. It's a regular web-application with a maven2 build. I've got things mostly working to the point that it's possible to build, deploy and debug the application (including JSPs) from within IDEA. I have some remaining issues that I'm looking for feedback on, however:

First off, I've been trying both local and remote WebLogic run configs, and I can't really see any advantage to using Local over Remote (remote but running on localhost still), aside from giving IDEA the ability to start and stop the server instance. I was hoping a local config would use an exploded deployment and enable the use of FastSwap or at least reload JSPs without a full redeploy required. However, I can't see that deploying a war or an exploded dir made any difference in a local config. Am I simply doing it wrong?

- I can't seem to get my project set up in such a way that I can simply save JSPs, JavaScript files and so on and then reload the page in my browser to test changes. At present, I must do a full redeploy, which takes longer and also wipes session data so that I have to redo wizard steps and such to get back to the point I was testing. Is it possible to set IDEA up so that I can just save my JSP and reload the page in browser?

In IDEA 9 you'll be able to quickly update running application (see http://blogs.jetbrains.com/idea/2009/10/update-a-running-javaee-application/).

- Less important than the first point: I have not been able to find a setup that enables me to utilize WebLogic 10.3's FastSwap feature (basically limited and BEA-proprietary JavaRebel that reloads modified classes in WEB-INF/classes for an exploded application without the need to redeploy). Is it possible to get this working from within IDEA? The point about JSPs is more important to me as classes are easier to test outside the container with unit tests and whatnot, and there's always the real JavaRebel as an alternative, but it would be nice to have it working since it's there..

Feel free to create a feature request in our issue tracker (http://youtrack.jetbrains.net/issues/IDEA).

Lastly, some minor annoyances I've currently been more or less able to work around:
1. I get the following warning: "Cannot debug Web facet 'Web': debugging is off. Clicking the FIX button injects an element into weblogic.xml that makes subsequent redeploys fail because of schema validation. A search of this list seems to indicate that this check may be based on this element being needed for JSP debugging in WLS8. This no longer seems to be the case as my weblogic.xml does not contain this element but JSP debugging is  actually working. Not quite sure what enables it now - possibly running the server in devmode is sufficient.

This warning is fixed in IDEA 9 builds.

2. When I launch the WebLogic run config and the app redeploys, the Web Facet being deployed is displayed with an orange exclamation mark under IDEA's Console-tab. The message is "Error during facet deployment, see error-log for details". However, deployment seems to have gone fine. The final entry of the serverlog is typically something like "<BEA-149074> <Successfully completed deployment task: deploy application myAppWeb on wlServer.>.

Perhaps this one was fixed in IDEA 9 builds as well.

3. A third issue is that the weblogic integration seems fairly fragile. I'm not sure if this is on the IDEA or the WebLogic side of things (I've been having simular issues in WebLogic Workshop), but I frequently run into issues where I have to manually clean up and restart the server with the WebLogic administration console due to a failed deployment that simply won't go away. A reasonably reproducible way to trigger such a "locked state" from IDEA seems to be clicking "Deploy all" under Console again while another deploy is running. It will basically cause this:1. The first time: "com.intellij.javaee.weblogic.runDebug.weblogicServerInstances.version9.mbeansModel.JMWrappedException: javax.management.MBeanException: MBean invoke failed: weblogic.management.provider.EditSaveChangesFailedException: Can not save changes while prepare changes are still in progress".

2. So that was expected as the first redeploy is already running (and will also complete successfully). This is where the troubles begin however. From now on, all attempts to redeploy will fail with the following error until I manually clean up using the WebLogic admin console: com.intellij.javaee.weblogic.runDebug.weblogicServerInstances.version9.mbeansModel.JMWrappedException: javax.management.MBeanException: MBean invoke failed: weblogic.management.ManagementException: No application named 'myAppWeb' exists for operation undeploy


The strange thing about #2 is that the deployment status gets a green "OK", as opposed to the orange exclamation mark/warning when it was actually successful

Could you please file a bug in our issue tracker (http://youtrack.jetbrains.net/issues/IDEA)?

--
Nikolay Chashnikov
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

I faced the same issue and couldn't find working solution in any forums: I tried the following and it worked  idea is, first find out the application which thrown this error? and change the sequence of deployment to weblogic.  1) edit weblogic configuration from intellij/IDE and undeploy all artifacts 2) shutdown the weblogic server 3) start weblogic server from intellij/IDE  4) edit weblogic configuration and deploy only one application which worked 5) now deploy other web application which doesn't thrown any error 6) finally deploy the application which gave you the error, this should be the last in the order  this worked for us, it may work for you as well and full detail is available at weblogic intellij!!

0

Please sign in to leave a comment.