... also be aware of problems that may arise if you deploy 2 different apps 
that both have the same package naming as derived from the simple-app artifact:

eg. both having a 'domainapp.application.manifest.DomainAppAppManifest', which 
as well leads to unintended class-loading behavior.

On 2018/05/27 05:48:06, Andi Huber <ahu...@apache.org> wrote: 
> Hi Gerrie,
> 
> most time I do see these kind of issues, the reason is class-loading related. 
> From what you describe I'd have a look at your tomcat installation and make 
> sure that there is no jar file clash:
> 
> Tomcat loads classes from different places before it locks up your deployed 
> WAR file. Also you may try to purge any files left over from previous 
> deployments, before giving it another try. (If you are deploying within an 
> IDE eg. Eclipse, there are additional folders you have to be aware of, where 
> file might be left over from previous deployments.)
> 
> Hope that helps.
> 
> Cheers Andi.
> 
> On 2018/05/27 04:48:49, Gerrie Myburgh <gerrie.mybu...@yahoo.co.uk.INVALID> 
> wrote: 
> > Hi,
> > I have changed simple app to incude another module and tried to deploy it 
> > to tomcat. But when the application starts up in tomcat I get the following 
> > error.
> > Caused by: java.lang.NoSuchMethodError: 
> > org.apache.isis.applib.AppManifestAbstract$Builder.withConfigurationPropertiesFile(Ljava/lang/Class;Ljava/lang/String;[Ljava/lang/String;)Lorg/apache/isis/applib/AppManifestAbstract$Builder;
> >  at 
> > domainapp.application.manifest.DomainAppAppManifest.<clinit>(DomainAppAppManifest.java:38)
> >  at 
> > java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native
> >  Method) at 
> > java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
> >  at 
> > java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> >  at 
> > java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:488) 
> > at java.base/java.lang.Class.newInstance(Class.java:560) at 
> > org.apache.isis.core.commons.factory.InstanceUtil.createInstance(InstanceUtil.java:125)
> >  at 
> > org.apache.isis.core.commons.factory.InstanceUtil.createInstance(InstanceUtil.java:103)
> >  at 
> > org.apache.isis.core.commons.factory.InstanceUtil.createInstance(InstanceUtil.java:42)
> >  at 
> > org.apache.isis.core.runtime.systemusinginstallers.IsisComponentProviderUsingInstallers.appManifestFrom(IsisComponentProviderUsingInstallers.java:92)
> >  at 
> > org.apache.isis.core.runtime.systemusinginstallers.IsisComponentProviderUsingInstallers.<init>(IsisComponentProviderUsingInstallers.java:54)
> >  at 
> > org.apache.isis.core.runtime.runner.IsisInjectModule.provideIsisSessionFactory(IsisInjectModule.java:111)
> >  at 
> > org.apache.isis.core.runtime.runner.IsisInjectModule$$FastClassByGuice$$a813f90e.invoke(<generated>)
> >  at 
> > com.google.inject.internal.ProviderMethod$FastClassProviderMethod.doProvision(ProviderMethod.java:264)
> >       
> > As far as I can see I am loading the correct version of the library 
> > (isis-core-applib-1.16.2.jar file) in tomcat as included in the war file. 
> > When the program runs in IDEA IDE with jetty it runs with no problems. The 
> > code where the problem originates from is :
> > package domainapp.application.manifest;
> > 
> > import 
> > domainapp.application.fixture.DomainAppApplicationModuleFixtureSubmodule;
> > import 
> > domainapp.application.services.DomainAppApplicationModuleServicesSubmodule;
> > import domainapp.modules.simple.dom.SimpleModuleDomSubmodule;
> > import domainapp.modules.system.dom.SystemModuleDomSubmodule;
> > import org.apache.isis.applib.AppManifestAbstract;
> > 
> > /**
> >  * Bootstrap the application.
> >  */
> > public class DomainAppAppManifest extends AppManifestAbstract {
> > 
> >     public static final Builder APPBUILDER = Builder.forModules(
> >                     SystemModuleDomSubmodule.class,
> >                     SimpleModuleDomSubmodule.class,
> >                     DomainAppApplicationModuleFixtureSubmodule.class,
> >                     DomainAppApplicationModuleServicesSubmodule.class,
> >                     org.isisaddons.module.security.SecurityModule.class
> >             )
> >             .withConfigurationPropertiesFile(DomainAppAppManifest.class,
> >                     "isis.properties",
> >                     "authentication_shiro.properties",
> >                     "persistor_datanucleus.properties",
> >                     "viewer_restfulobjects.properties",
> >                     "viewer_wicket.properties"
> >             )
> >             .withAdditionalServices(
> >                     
> > org.isisaddons.module.security.dom.password.PasswordEncryptionServiceUsingJBcrypt.class,
> >                     
> > org.isisaddons.module.security.dom.permission.PermissionsEvaluationServiceAllowBeatsVeto.class
> >             )
> >             .withAuthMechanism("shiro");
> > 
> >     public DomainAppAppManifest() {
> >         super(APPBUILDER);
> >     }
> > 
> > }Has problem cropped up before, if so how can it be resolved?
> > ThanksGerrie
> 

Reply via email to