The solution is to specify resources in maven-war-plugin http://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html
Kinski wrote: > > Hi, > > I am re-factoring a legacy web services app as a Maven project which is > now complete apart from one obstacle. I am using placeholders for any > variations relating to local, live and dev use. These are defined as > <properties> within each relevant <profile> in the pom.xml. > > All are resolving fine, bar one (the wsdl file) because it is required in > the webapp home (i.e. http://localhost:8080/appname/definitions/file.wsdl) > rather than within WEB-INF/classes (which is the default location for > <targetPath>) > > Currently the file is stored in src/main/webapps/definitions > > To be clear, it resolves fine if I place the definitions folder in > src/main/resources but then it's destination in the war is > WEB-INF/classes/definitions/file.wsdl > (which is to be avoided if possible as the url is preferred not to change > as the app is already in live use) > > I have experimented with the alternative solution of using an additional > resource directory... > > <resource> > <directory>src/main/webapps</directory> > <filtering>true</filtering> > </resource> > > using for example <targetPath>../tester</targetPath> > > But this actually creates the destination outside the war file. > > So my question is how can I get Maven to recognise my wsdl file as a > resource which needs its placholder resolved AND keep its destination > outside WEB-INF/classes in the root of the webapp? > > As I am new to web services, I am also curious if there are any best > practices relating to where a wsdl file should be stored within a webapp. > > Many Thanks, > > Matthew > ----- Regards, Matthew -- View this message in context: http://www.nabble.com/Profiles-and-Resources-%28wsdl%29-tp17649887p17665516.html Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]