From a7856633ec99aa650ccd0a800e59323b4b1319c9 Mon Sep 17 00:00:00 2001 From: Ole Hejlskov Date: Tue, 7 Apr 2015 17:37:24 +0200 Subject: [PATCH] Set virtual class path up correctly. Running 'mvn compile' makes sure the changes end up in target/${project.build.finalName}/config. This causes issues when changing existing files after starting/restarting, since integration-test makes the files appear in target/test-classes. The app would then only serve the file in target/test-classes and ignore the rest. By switching these we can strive for having 'mvn compile' do everything we need to ensure hot reloading works. --- .../runner/tomcat/context-repo.xml | 9 ++++++- .../runner/tomcat/context-share.xml | 9 ++++++- .../archetype-resources/tomcat/context.xml | 12 ++++++++-- .../archetype-resources/tomcat/context.xml | 24 +++++++++++++++---- poms/alfresco-sdk-parent/pom.xml | 3 +++ 5 files changed, 48 insertions(+), 9 deletions(-) diff --git a/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-repo.xml b/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-repo.xml index 95b83dd4..88c314f9 100644 --- a/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-repo.xml +++ b/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-repo.xml @@ -16,9 +16,16 @@ extraResourcePaths="/=${project.parent.basedir}/repo-amp/target/repo-amp/web" /> + + virtualClasspath="${project.parent.basedir}/repo-amp/target/classes;${project.parent.basedir}/repo-amp/target/repo-amp/config;${project.parent.basedir}/repo-amp/target/test-classes" /> diff --git a/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-share.xml b/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-share.xml index 65d1c488..d2ae9316 100644 --- a/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-share.xml +++ b/archetypes/alfresco-allinone-archetype/src/main/resources/archetype-resources/runner/tomcat/context-share.xml @@ -13,9 +13,16 @@ extraResourcePaths="/=${project.parent.basedir}/share-amp/target/share-amp/web" /> + + virtualClasspath="${project.parent.basedir}/share-amp/target/classes;${project.parent.basedir}/share-amp/target/share-amp/config;${project.parent.basedir}/share-amp/target/test-classes" /> diff --git a/archetypes/alfresco-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml b/archetypes/alfresco-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml index 0862d9c0..3a6aef29 100644 --- a/archetypes/alfresco-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml +++ b/archetypes/alfresco-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml @@ -13,10 +13,18 @@ - + + + virtualClasspath="${project.build.outputDirectory};${project.build.directory}/${project.build.finalName}/config;${project.build.testOutputDirectory}" /> + diff --git a/archetypes/share-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml b/archetypes/share-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml index a5347d33..0b2c4d4d 100644 --- a/archetypes/share-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml +++ b/archetypes/share-amp-archetype/src/main/resources/archetype-resources/tomcat/context.xml @@ -1,15 +1,29 @@ + +--> + - - - - + + + + + diff --git a/poms/alfresco-sdk-parent/pom.xml b/poms/alfresco-sdk-parent/pom.xml index aca83146..1c26246e 100644 --- a/poms/alfresco-sdk-parent/pom.xml +++ b/poms/alfresco-sdk-parent/pom.xml @@ -492,6 +492,9 @@ 1.0 + compile execute