Revert "jetty-9 moved the jetty demos to webapps-demos controlled by start.d/demos.ini"
This reverts commit 4bd36e3d38
.
This commit is contained in:
parent
a99a3ae254
commit
ebd807b904
|
@ -58,9 +58,6 @@ import org.eclipse.jetty.xml.XmlConfiguration;
|
|||
* be configured by the XML and only the XML is deployed.
|
||||
* </ul>
|
||||
*
|
||||
* <p>When deploying XML files, the property deployer.file is set to the file itself and
|
||||
* deployer.dir is set to the directory of the XML file</p>
|
||||
*
|
||||
*/
|
||||
@ManagedObject("Provider for start-up deployement of webapps based on presence in directory")
|
||||
public class WebAppProvider extends ScanningAppProvider
|
||||
|
@ -268,8 +265,6 @@ public class WebAppProvider extends ScanningAppProvider
|
|||
if (resource.exists() && FileID.isXmlFile(file))
|
||||
{
|
||||
XmlConfiguration xmlc = new XmlConfiguration(resource.getURL());
|
||||
xmlc.getProperties().put("deployer.file",file.getCanonicalPath());
|
||||
xmlc.getProperties().put("deployer.dir",file.getParent());
|
||||
|
||||
xmlc.getIdMap().put("Server",getDeploymentManager().getServer());
|
||||
if (getConfigurationManager() != null)
|
||||
|
|
|
@ -99,7 +99,7 @@
|
|||
<type>war</type>
|
||||
<overWrite>true</overWrite>
|
||||
<includes>**</includes>
|
||||
<outputDirectory>${assembly-directory}/webapps-demos</outputDirectory>
|
||||
<outputDirectory>${assembly-directory}/webapps</outputDirectory>
|
||||
<destFileName>test.war</destFileName>
|
||||
</artifactItem>
|
||||
<artifactItem>
|
||||
|
@ -109,7 +109,7 @@
|
|||
<type>war</type>
|
||||
<overWrite>true</overWrite>
|
||||
<includes>**</includes>
|
||||
<outputDirectory>${assembly-directory}/webapps-demos</outputDirectory>
|
||||
<outputDirectory>${assembly-directory}/webapps</outputDirectory>
|
||||
<destFileName>async-rest.war</destFileName>
|
||||
</artifactItem>
|
||||
<artifactItem>
|
||||
|
@ -473,7 +473,7 @@
|
|||
<type>war</type>
|
||||
<overWrite>true</overWrite>
|
||||
<includes>**</includes>
|
||||
<outputDirectory>${assembly-directory}/webapps-demos</outputDirectory>
|
||||
<outputDirectory>${assembly-directory}/webapps</outputDirectory>
|
||||
<destFileName>spdy.war</destFileName>
|
||||
</artifactItem>
|
||||
</artifactItems>
|
||||
|
|
|
@ -1,23 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure.dtd">
|
||||
|
||||
<!-- =============================================================== -->
|
||||
<!-- Create the Demo deployment manager provider -->
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||
<!-- Adds an WebAppProvider for the webapps-demos directory. -->
|
||||
<!-- This configuration is enabled by $JETTY_HOME/start.d/demos.ini -->
|
||||
<!-- =============================================================== -->
|
||||
<Configure id="Server" class="org.eclipse.jetty.server.Server">
|
||||
<Ref id="DeploymentManager">
|
||||
<Call id="demoProvider" name="addAppProvider">
|
||||
<Arg>
|
||||
<New class="org.eclipse.jetty.deploy.providers.WebAppProvider">
|
||||
<Set name="monitoredDirName"><Property name="jetty.home" default="." />/webapps-demos</Set>
|
||||
<Set name="defaultsDescriptor"><Property name="jetty.home" default="." />/etc/webdefault.xml</Set>
|
||||
<Set name="scanInterval">1</Set>
|
||||
<Set name="extractWars">true</Set>
|
||||
</New>
|
||||
</Arg>
|
||||
</Call>
|
||||
</Ref>
|
||||
</Configure>
|
|
@ -1,9 +0,0 @@
|
|||
|
||||
# Add the jetty client used by some demos
|
||||
OPTIONS=client
|
||||
|
||||
# Add the test authentication realm
|
||||
etc/test-realm.xml
|
||||
|
||||
# Add the deployer provider for webapps-demos
|
||||
etc/jetty-demos.xml
|
|
@ -78,23 +78,16 @@
|
|||
#===========================================================
|
||||
|
||||
#===========================================================
|
||||
# Common Options
|
||||
# Use the core server jars on the classpath
|
||||
# Enables websocket
|
||||
# Default Server Options
|
||||
# Use the core server jars with websocket on the classpath
|
||||
# Add the contents of the resources directory to the classpath
|
||||
# Add jars discovered in lib/ext to the classpath
|
||||
#-----------------------------------------------------------
|
||||
OPTIONS=Server
|
||||
OPTIONS=websocket
|
||||
OPTIONS=resources
|
||||
OPTIONS=ext
|
||||
#OPTIONS=client
|
||||
#===========================================================
|
||||
|
||||
#===========================================================
|
||||
# Include the core jetty configuration file
|
||||
# Lookup additional ini files in start.d
|
||||
#-----------------------------------------------------------
|
||||
OPTIONS=Server,websocket,resources,ext
|
||||
etc/jetty.xml
|
||||
start.d/
|
||||
#===========================================================
|
||||
|
||||
#===========================================================
|
||||
|
@ -121,6 +114,7 @@ etc/jetty-jmx.xml
|
|||
OPTIONS=jsp
|
||||
#===========================================================
|
||||
|
||||
|
||||
#===========================================================
|
||||
# Annotations JNDI JASS processing
|
||||
#-----------------------------------------------------------
|
||||
|
@ -181,11 +175,3 @@ etc/jetty-requestlog.xml
|
|||
# etc/jetty-debug.xml
|
||||
# etc/jetty-ipaccess.xml
|
||||
#===========================================================
|
||||
|
||||
#===========================================================
|
||||
# Lookup additional ini files in start.d
|
||||
# THE DEMO WEBAPPS ARE CONFIGURED IN start.d/demo.ini
|
||||
#-----------------------------------------------------------
|
||||
start.d/
|
||||
#===========================================================
|
||||
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
|
||||
This is the webapps demo directory for the Jetty Server.
|
||||
It is enabled by the file $JETTY_HOME/start.d/demos.ini
|
||||
Remove that file or comment out it's contents to disable
|
||||
the jetty demonstrations.
|
||||
|
|
@ -2,33 +2,24 @@
|
|||
This directory is scanned by the WebAppDeployer provider for web
|
||||
applications to deploy using the following conventions:
|
||||
|
||||
+ A file matching the pattern *.war will be deployed as a standard web
|
||||
application with the context path set from the files basename.
|
||||
So a file called "example.war" will be deployed with a context path of /example
|
||||
and will be served at URLs like http://localhost:8080/example/).
|
||||
If the base name is root, then the context path is /. If example.war and example/
|
||||
+ A directory called example/ will be deployed as a standard web
|
||||
application if it contains a WEB-INF/ subdirectory, otherwise it will be
|
||||
deployed as context of static content. The context path will be /example
|
||||
(eg http://localhost:8080/example/) unless the base name is root, in
|
||||
which case the context path is /. If the directory name ends with ".d"
|
||||
it is ignored (by may be used by explicit configuration).
|
||||
|
||||
+ A file called example.war will be deployed as a standard web application
|
||||
with the context path /example (eg http://localhost:8080/example/). If he
|
||||
base name is root, then the context path is /. If example.war and example/
|
||||
exist, then only the WAR is deployed (which may use the directory as an
|
||||
unpack location).
|
||||
|
||||
+ A directory will be deployed as a standard web application if it
|
||||
contains a WEB-INF/ subdirectory, otherwise it will be deployed as
|
||||
context of static content. The context path will be the filename.
|
||||
So a directory called "example/" will have a context path of /example
|
||||
If the basename is "root", then the context path is /.
|
||||
If the directory name ends with ".d" it is ignored (and may be used
|
||||
to hold other configuration files).
|
||||
|
||||
|
||||
+ An XML file will be deployed as a context whose configuration is
|
||||
defined by the XML. The context path must be set by the configuration
|
||||
itself. If "example.xml" and "example.war" exist, then only the XML
|
||||
is deployed (which may use the war in its configuration).
|
||||
+ An XML file like example.xml will be deployed as a context whose
|
||||
configuration is defined by the XML. The context path must be set by
|
||||
the configuration itself. If example.xml and example.war exist, then
|
||||
only the XML is deployed (which may use the war in its configuration).
|
||||
|
||||
This directory is scanned for additions, removals and updates
|
||||
for hot deployment.
|
||||
|
||||
The jetty demo webapps are not served from this directory. Instead
|
||||
the $JETTY_HOME/start.d/demo.ini file configures the
|
||||
$JETTY_HOME/webapps-demos directory as an alternate webapps deployment
|
||||
directory.
|
||||
|
||||
|
|
Before Width: | Height: | Size: 101 KiB After Width: | Height: | Size: 101 KiB |
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 17 KiB |
|
@ -0,0 +1,3 @@
|
|||
|
||||
This directory contains example context XML that may be deployed by
|
||||
moving/copying/linking them to the ../../webapps directory.
|
|
@ -1,7 +1,6 @@
|
|||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure.dtd">
|
||||
|
||||
<!-- Example of a MovedContextHandler -->
|
||||
<Configure class="org.eclipse.jetty.server.handler.MovedContextHandler">
|
||||
<Set name="contextPath">/oldContextPath</Set>
|
||||
<Set name="newContextURL">/test/dump/newContextPath</Set>
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.eclipse.org/configure.dtd">
|
||||
|
||||
<!--
|
||||
Configure a custom context for serving static resources
|
||||
|
||||
This context contains only a ResourceHandler
|
||||
to serve static html files and images.
|
||||
-->
|
||||
|
||||
<Configure class="org.eclipse.jetty.server.handler.ContextHandler">
|
||||
<Set name="contextPath">/resources</Set>
|
||||
<Set name="resourceBase"><SystemProperty name="jetty.home" default="."/>/resources/</Set>
|
||||
<Set name="handler">
|
||||
<New class="org.eclipse.jetty.server.handler.ResourceHandler">
|
||||
<Set name="welcomeFiles">
|
||||
<Array type="String">
|
||||
<Item>index.html</Item>
|
||||
</Array>
|
||||
</Set>
|
||||
<Set name="cacheControl">max-age=3600,public</Set>
|
||||
</New>
|
||||
</Set>
|
||||
|
||||
</Configure>
|
||||
|
|
@ -0,0 +1 @@
|
|||
etc/test-realm.xml
|
|
@ -20,7 +20,7 @@ detected.
|
|||
<!-- + war OR resourceBase -->
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||
<Set name="contextPath">/test</Set>
|
||||
<Set name="war"><Property name="deployer.dir"/>/test.war</Set>
|
||||
<Set name="war"><SystemProperty name="jetty.home" default="."/>/webapps/test.war</Set>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||
<!-- Optional context configuration -->
|
||||
|
@ -28,7 +28,7 @@ detected.
|
|||
<Set name="extractWAR">true</Set>
|
||||
<Set name="copyWebDir">false</Set>
|
||||
<Set name="defaultsDescriptor"><SystemProperty name="jetty.home" default="."/>/etc/webdefault.xml</Set>
|
||||
<Set name="overrideDescriptor"><Property name="deployer.dir" default="."/>/test.d/override-web.xml</Set>
|
||||
<Set name="overrideDescriptor"><SystemProperty name="jetty.home" default="."/>/webapps/test.d/override-web.xml</Set>
|
||||
|
||||
<!-- virtual hosts
|
||||
<Set name="virtualHosts">
|
Loading…
Reference in New Issue