war

Checking for corrupt war file after mvn install

Is there a maven command that will verify that a WAR file is valid and not corrupt? Or is there some other program or technique to validate zip files? I'm on Ubuntu 9.10, so a linux solution is preferred. On occasion, I end up with a corrupt WAR file after doing mvn clean and mvn install on my project. If I extract the WAR file to my h...

Which application server should i choose for my project ?

Hi folks, I am currently developing an application for some researchers in my university.It's a small java program that you can use by command line. The next step is to package that program and deploy it to an application server. Some clients program will submit requests to the server who will call the tool that I wrote. Lately, we will ...

`sbt package` results in huge war file - how to make it smaller?

Hey all, I'm currently using SBT to manage my Lift project. I'd like to deploy it, but when I run 'sbt package' it produces a 60MB war file. This seems pretty large - are there ways I could cut down the size? Thanks! ...

Error when deploying WAR file

Hi, I have a war file and when deploying it thro the admin console in websphere i am getting the following error after specifying the war file location and the context-root. The EAR file might be corrupt or incomplete. org.eclipse.jst.j2ee.commonarchivecore.internal.exception.DeploymentDescriptorLoadException: WEB-INF/web.xml Any...

How to generate an ear file from a maven-archetype-webapp artifact?

I currently have a project built with maven-archetype-webapp artifact. The default packaging for this project is war. Is it possible for me to insert the maven-ear-plugin in this webapp pom.xml generate an ear file that contains this project war? I tried that, but the war file doesn't get embedded in the generated ear file. It has ever...

Eclipse Error Exporting Web Project as WAR

Hi I have the following error when I export my war file org.eclipse.core.runtime.CoreException: Extended Operation failure: org.eclipse.jst.j2ee.internal.web.archive.operations.WebComponentExportOperation at org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizard.performFinish(DataModelWizard.java:189) at org.e...

How to deploy war file in Filezilla FTP?

How to deploy war file in Filezila FTP? ...

Add subversion revision to war manifest using maven2

I want to find a maven native (i.e. without calling external programs) to inject the svn revision in the war manifest. Does anybody know a way to do that? I found mention to how to add the subversion revision to manifests in jar files but not with war files. I searched SO but could not find this issue specifically. ...

Store xml files in resources folder (WAR), read from code

Hi, I have different XML-files in my 'src/main/recources' folder, and I'd like to read them from my webapplication. File f = new File("file1.xml"); f.getAbsolutePath(); The code gets invoked inside a WebService, and this prints out 'C:\Users\Administrator' when I look inside the Tomcat-server-output. My current solution is to put the...

How do I create a WAR file using NetBeans' generated ant script?

Hi. I'm trying to configure an automated build process, and I need to get a WAR file to deploy to Tomcat. The project was created in Netbeans, which automatically generates an ant script. I think when I click "Clean and Build Project" from the menu it runs a series of ant targets and generates the WAR that I need. So does anyone know...

Tomcat reporting 404 error on all of newly deployed WAR files?

I deployed a WAR file into $TOMCAT_HOME/webapps by copying the file into the directory, just like I've done a thousand times before. Tomcat detects the WAR and inflates it. I can traverse the directory tree on my server at the command line (it's Fedora). But when I address the webapp within my client machine's browser, I get nothing b...

Maven String Replace of Text Web Resources

I have a Maven web application with text files in src/main/webapp/textfilesdir As I understand it, during the package phase this textfilesdir directory will be copied into the target/project-1.0-SNAPSHOT directory, which is then zipped up into a target/project-1.0-SNAPSHOT.war Problem Now, I need to do a string repl...

Eclipse WAR with 2 projects?

I am trying to export a WAR file from Eclipse. I have a "Dynamic Web Project". But I need classes created for two other projects, one a plain Java project, the other another web project. So in the Build Config I told it to add the other projects and on the "Order and Export" page I clicked the boxes to export the second and third project...

In IDEA, I setup to deploy using web app exploded, how do to .war file?

Using IDEA and tomcat I setup a simple spring mvc app (thanks to you guys) and it was deploying using a 'web app exploded' format. Is a .war file the same thing, except in a single file appname.war? How can I configure IDEA to do this? how do I have IDEA make a .war file during compilation and/or deployment? how do I link this to t...

maven war plugin giving strange output!

hi people, I am getting some very weird behaviour from maven that I have never seen before. Basicaly I refactored some classes, like util.constants (lower c) to util.Constants (capital C), but when I run the maven build to produce a WAR from the command line (mvn clean install), it builds the war project with util.constants (lower c). U...

maven warpath plugin

Hi, After following what was in this thread http://stackoverflow.com/questions/1769586/maven-war-dependency I tried to apply this to my project. The project I'm working on requires to use some of the classes provided by a WAR file. I've added to my pom.xml the following: .... com.foo my-war 1.0.2/v...

Tomcat unable to find jsp in war file

I recently switched one of my static html files to a Spring controller that uses a JSP to render its view. I use jetty to test locally and local testing shows the page rendering fine. Upon deploying to our test server, which uses Tomcat 6.0.26, I get the following exception: javax.servlet.ServletException: Could not get RequestDispatche...

Java: Accessing properties file inside a war

I already searched StackOverflow for "properties inside war", but none of the results worked for my case. I am using Eclipse Galileo and GlassFish v3 to develop a set of web services. I am using a "dynamic web project" with the following structure Src -java_code_pkg_1 -java_code_pkg_2 -com.company.config --configfile.properties WebCon...

Problems deploying WAR file from Netbeans to Tomcat

I'm trying to configure build.xml files for build forge, but it seems like I am having trouble with the libraries required for the java servlet pages. I am actually trying to use OWASP's AntiSamy library but I keep getting a Policy Exception followed by a file not found org.owasp.validator.html.PolicyException: java.io.FileNotFoundE...

When does grails.config.locations get processed in Grails?

I am using grails 1.2.1 and would like to specify external configuration (properties) files for the war file for my application. I understand from documentation that the proper way to do this is to specify the grails.config.locations list in the Config.groovy file. When I do that, however, the properties that should be set are not av...