I've been doing core java for awhile. I'm kind of new to web environment...
To be more specific new to generating WAR files.
My development environment is Windows, Eclipse and Tomcat.
Target environment is Unix and WebLogic.
I've updated and successfully tested 3 java classes and 1 JSP in an existing web application. Now I'm ready to build the war file and deploy it on the test environment on Unix.
The [grumpy] systems administrator instructed me to build the WAR file as follows (he is unaware if a Build.XML file exists):
1. In Windows, use the 7zip application to "browse/explore" into the [existing] WAR file
2. Drag and drop the updated class files and jsp file from Tomcat into the WAR file
The WAR file deployed on Weblogic, and the web app did came up, but the [JSP] page that I updated is not rendering. The sys admin is blaming my code, but I don't think that is the problem.
My question is: Is this a valid way update a WAR file?
Thanks, I just need validation. If this is a valid way to update a WAR file then I'll continue down this path.
It's a valid mechanism only if you don't screw it up by placing the files in the wrong location. I would use a slight modification to this process: rename the xxx.war file to xxx.zip, unzip it into en empty directory, copy the files to the correct directories, and then zip it back up (making sure that you don't accidentally make xxx the base directory!), and rename the xxx.zip file to xxx.war. I have done this often with JAR files when I want to change a single class.
Warning: if you do this, make sure you use standard zip compression, Java cannot handle some of the compression mechanisms provided by 7Zip (avoid any mechanism that claims to provide better compression).
Of course, using a standard build script to rebuild from source is always the preferred method.