|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.jetty.util.component.AbstractLifeCycle org.eclipse.jetty.deploy.providers.ScanningAppProvider org.eclipse.jetty.osgi.boot.OSGiAppProvider
public class OSGiAppProvider
AppProvider for OSGi. Supports the configuration of ContextHandlers and WebApps. Extends the AbstractAppProvider to support the scanning of context files located outside of the bundles.
This provider must not be called outside of jetty.boot: it should always be called via the OSGi service listener.
This provider supports the same set of parameters than the WebAppProvider as it supports the deployment of WebAppContexts. Except for the scanning of the webapps directory.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle |
---|
AbstractLifeCycle.AbstractLifeCycleListener |
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle |
---|
LifeCycle.Listener |
Field Summary |
---|
Fields inherited from class org.eclipse.jetty.deploy.providers.ScanningAppProvider |
---|
_filenameFilter |
Fields inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle |
---|
_listeners, FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING |
Constructor Summary | |
---|---|
OSGiAppProvider()
Default OSGiAppProvider consutructed when none are defined in the jetty.xml configuration. |
|
OSGiAppProvider(File contextsDir)
Default OSGiAppProvider consutructed when none are defined in the jetty.xml configuration. |
Method Summary | |
---|---|
void |
addContext(org.osgi.framework.Bundle contributor,
String pathInBundle,
ContextHandler context)
|
void |
addContext(String originId,
ContextHandler context)
|
protected App |
createApp(String filename)
Called by the scanner of the context files directory. |
ContextHandler |
createContextHandler(App app)
Returns the ContextHandler that was created by WebappRegistractionHelper |
String |
getContextXmlDir()
The context xml directory. |
File |
getContextXmlDirAsFile()
The context xml directory. |
String |
getDefaultsDescriptor()
Get the defaultsDescriptor. |
String |
getTldBundles()
|
boolean |
isExtract()
|
boolean |
isParentLoaderPriority()
Get the parentLoaderPriority. |
void |
removeContext(ContextHandler context)
|
void |
setContextXmlDir(String contextsDir)
Set the directory in which to look for context XML files. |
void |
setDefaultsDescriptor(String defaultsDescriptor)
Set the defaultsDescriptor. |
void |
setDeploymentManager(DeploymentManager deploymentManager)
Set the Deployment Manager |
void |
setExtract(boolean extract)
|
void |
setParentLoaderPriority(boolean parentLoaderPriority)
Set the parentLoaderPriority. |
void |
setTldBundles(String tldBundles)
|
Methods inherited from class org.eclipse.jetty.deploy.providers.ScanningAppProvider |
---|
doStart, doStop, fileAdded, fileChanged, fileRemoved, getDeployedApps, getDeploymentManager, getMonitoredDir, getScanInterval, isRecursive, setMonitoredDir, setMonitoredDir, setRecursive, setScanInterval |
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle |
---|
addLifeCycleListener, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.jetty.util.component.LifeCycle |
---|
addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop |
Constructor Detail |
---|
public OSGiAppProvider()
public OSGiAppProvider(File contextsDir) throws IOException
contextsDir
-
IOException
Method Detail |
---|
public ContextHandler createContextHandler(App app) throws Exception
createContextHandler
in interface AppProvider
app
- The App
IOException
Exception
AppProvider
public void setDeploymentManager(DeploymentManager deploymentManager)
AppProvider
setDeploymentManager
in interface AppProvider
setDeploymentManager
in class ScanningAppProvider
AppProvider
public void addContext(org.osgi.framework.Bundle contributor, String pathInBundle, ContextHandler context) throws Exception
context
-
Exception
public void addContext(String originId, ContextHandler context) throws Exception
context
-
Exception
protected App createApp(String filename)
createApp
in class ScanningAppProvider
filename
- The file that is the context.xml. It is resolved by
Resource.newResource(String)
public void removeContext(ContextHandler context) throws Exception
Exception
public boolean isParentLoaderPriority()
public void setParentLoaderPriority(boolean parentLoaderPriority)
parentLoaderPriority
- the parentLoaderPriority to setpublic String getDefaultsDescriptor()
public void setDefaultsDescriptor(String defaultsDescriptor)
defaultsDescriptor
- the defaultsDescriptor to setpublic File getContextXmlDirAsFile()
public String getContextXmlDir()
public boolean isExtract()
public void setExtract(boolean extract)
public void setContextXmlDir(String contextsDir)
If a webapp call "foo/" or "foo.war" is discovered in the monitored directory, then the ContextXmlDir is examined to see if a foo.xml file exists. If it does, then this deployer will not deploy the webapp and the ContextProvider should be used to act on the foo.xml file.
contextsDir
- ContextProvider
public void setTldBundles(String tldBundles)
tldBundles
- Comma separated list of bundles that contain tld jars
that should be setup on the jetty instances created here.public String getTldBundles()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |