Fix jetty-ee10-demo-jndi/jetty-webapp and ContextProvider

This commit is contained in:
Jan Bartel 2022-07-04 15:41:24 +10:00
parent dfb28c7af4
commit fc3fb15dc4
7 changed files with 16 additions and 11 deletions

View File

@ -296,7 +296,10 @@ public class ContextProvider extends ScanningAppProvider
}
else
{
throw new IllegalStateException("No ContextHandler for " + context);
if (LOG.isDebugEnabled())
LOG.debug("Not a context {}", context);
return null;
}
assert contextHandler != null;

View File

@ -23,7 +23,7 @@ ee10-websocket-jetty
ee10-demo-realm
[files]
webapps-ee10/ee10-demo-jetty.d/
webapps/ee10-demo-jetty.d/
basehome:modules/demo.d/ee10-demo-jetty.xml|webapps/ee10-demo-jetty.xml
basehome:modules/demo.d/ee10-demo-jetty-override-web.xml|webapps/ee10-demo-jetty.d/ee10-demo-jetty-override-web.xml
maven://org.eclipse.jetty.ee10.demos/jetty-ee10-demo-jetty-webapp/${jetty.version}/war|webapps/ee10-demo-jetty.war

View File

@ -45,7 +45,7 @@
</Arg>
<Arg>mail/Session</Arg>
<Arg>
<New class="org.eclipse.jetty.jndi.factories.MailSessionReference">
<New class="org.eclipse.jetty.ee10.jndi.factories.MailSessionReference">
<Set name="user">CHANGE-ME</Set>
<Set name="password">CHANGE-ME</Set>
<Set name="properties">

View File

@ -15,6 +15,7 @@ ee10-deploy
ext
jdbc
ee10-plus
ee10-jndi
ee10-demo-mock-resources
[files]

View File

@ -5,7 +5,7 @@
<!-- =============================================================== -->
<Configure id='wac' class="org.eclipse.jetty.ee9.webapp.WebAppContext">
<New id="tx" class="org.eclipse.jetty.plus.jndi.Transaction">
<New id="tx" class="org.eclipse.jetty.ee9.plus.jndi.Transaction">
<Arg>
<New class="org.example.MockUserTransaction" />
</Arg>
@ -19,7 +19,7 @@
<Set name="configurationDiscovered">true</Set>
<!-- Define an env entry with Server scope for java:comp/env -->
<New id="woggle" class="org.eclipse.jetty.plus.jndi.EnvEntry">
<New id="woggle" class="org.eclipse.jetty.ee9.plus.jndi.EnvEntry">
<Arg>
<Property name='server' />
</Arg>
@ -29,7 +29,7 @@
</New>
<!-- Define an env entry with webapp scope for java:comp/env -->
<New id="wiggle" class="org.eclipse.jetty.plus.jndi.EnvEntry">
<New id="wiggle" class="org.eclipse.jetty.ee9.plus.jndi.EnvEntry">
<Arg>
<Ref refid='wac' />
</Arg>
@ -39,13 +39,13 @@
</New>
<!-- Mail Session setup -->
<New id="xxxmail" class="org.eclipse.jetty.plus.jndi.Resource">
<New id="xxxmail" class="org.eclipse.jetty.ee9.plus.jndi.Resource">
<Arg>
<Ref refid='wac' />
</Arg>
<Arg>mail/Session</Arg>
<Arg>
<New class="org.eclipse.jetty.jndi.factories.MailSessionReference">
<New class="org.eclipse.jetty.ee9.jndi.factories.MailSessionReference">
<Set name="user">CHANGE-ME</Set>
<Set name="password">CHANGE-ME</Set>
<Set name="properties">
@ -61,7 +61,7 @@
</New>
<!-- A mock DataSource -->
<New id="mydatasource" class="org.eclipse.jetty.plus.jndi.Resource">
<New id="mydatasource" class="org.eclipse.jetty.ee9.plus.jndi.Resource">
<Arg>
<Ref refid='wac' />
</Arg>

View File

@ -14,8 +14,8 @@ webapp
deploy
[files]
webapps-ee10/root-ee10/
webapps-ee10/root-ee10/images/
webapps/root-ee10/
webapps/root-ee10/images/
basehome:modules/demo.d/ee10-root/index.html|webapps/root-ee10/index.html
basehome:modules/demo.d/ee10-root/jetty.css|webapps/root-ee10/jetty.css
basehome:modules/demo.d/ee10-root/images/jetty-pic.png|webapps/root-ee10/images/jetty-pic.png