Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Wilkins2011-04-11 23:51:51 -0400
committerGreg Wilkins2011-04-11 23:51:51 -0400
commit793872d2533125ea357b0e1c61228ca423f2fa72 (patch)
tree9382c5e1f541fcad112faf9a1db1b81c50ec9f9e
parentd3c5eddd799b7f89a156429668ab46e6a7990746 (diff)
downloadorg.eclipse.jetty.project-793872d2533125ea357b0e1c61228ca423f2fa72.tar.gz
org.eclipse.jetty.project-793872d2533125ea357b0e1c61228ca423f2fa72.tar.xz
org.eclipse.jetty.project-793872d2533125ea357b0e1c61228ca423f2fa72.zip
deprecated methods
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@3000 7e9141cc-0065-0410-87d8-b60c137991c4
-rw-r--r--jetty-deploy/src/main/config/etc/jetty-contexts.xml2
-rw-r--r--jetty-deploy/src/main/config/etc/jetty-webapps.xml2
-rw-r--r--jetty-deploy/src/test/resources/jetty-deploy-wars.xml2
-rw-r--r--jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/OSGiAppProvider.java8
-rw-r--r--jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/internal/serverfactory/ServerInstanceWrapper.java186
-rw-r--r--jetty-plus/src/main/config/etc/jetty-plus.xml2
6 files changed, 101 insertions, 101 deletions
diff --git a/jetty-deploy/src/main/config/etc/jetty-contexts.xml b/jetty-deploy/src/main/config/etc/jetty-contexts.xml
index 301491306c..caa7270dc3 100644
--- a/jetty-deploy/src/main/config/etc/jetty-contexts.xml
+++ b/jetty-deploy/src/main/config/etc/jetty-contexts.xml
@@ -14,7 +14,7 @@
<Call name="addAppProvider">
<Arg>
<New class="org.eclipse.jetty.deploy.providers.ContextProvider">
- <Set name="monitoredDir"><Property name="jetty.home" default="." />/contexts</Set>
+ <Set name="monitoredDirName"><Property name="jetty.home" default="." />/contexts</Set>
<Set name="scanInterval">1</Set>
</New>
</Arg>
diff --git a/jetty-deploy/src/main/config/etc/jetty-webapps.xml b/jetty-deploy/src/main/config/etc/jetty-webapps.xml
index 69c943beef..1071ae52d4 100644
--- a/jetty-deploy/src/main/config/etc/jetty-webapps.xml
+++ b/jetty-deploy/src/main/config/etc/jetty-webapps.xml
@@ -14,7 +14,7 @@
<Call id="webappprovider" name="addAppProvider">
<Arg>
<New class="org.eclipse.jetty.deploy.providers.WebAppProvider">
- <Set name="monitoredDir"><Property name="jetty.home" default="." />/webapps</Set>
+ <Set name="monitoredDirName"><Property name="jetty.home" default="." />/webapps</Set>
<Set name="defaultsDescriptor"><Property name="jetty.home" default="."/>/etc/webdefault.xml</Set>
<Set name="scanInterval">1</Set>
<Set name="contextXmlDir"><Property name="jetty.home" default="." />/contexts</Set>
diff --git a/jetty-deploy/src/test/resources/jetty-deploy-wars.xml b/jetty-deploy/src/test/resources/jetty-deploy-wars.xml
index f336584c66..6ab95b65d5 100644
--- a/jetty-deploy/src/test/resources/jetty-deploy-wars.xml
+++ b/jetty-deploy/src/test/resources/jetty-deploy-wars.xml
@@ -15,7 +15,7 @@
<Array type="org.eclipse.jetty.deploy.AppProvider">
<Item>
<New class="org.eclipse.jetty.deploy.providers.WebAppProvider">
- <Set name="monitoredDir"><SystemProperty name="jetty.home" />/webapps</Set>
+ <Set name="monitoredDirName"><SystemProperty name="jetty.home" />/webapps</Set>
<Set name="scanInterval">1</Set>
<Set name="tempDir"><Property name="jetty.home" default="target" />/workish</Set>
</New>
diff --git a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/OSGiAppProvider.java b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/OSGiAppProvider.java
index cf31174c98..efb27ee819 100644
--- a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/OSGiAppProvider.java
+++ b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/OSGiAppProvider.java
@@ -133,7 +133,7 @@ public class OSGiAppProvider extends ScanningAppProvider implements AppProvider
public OSGiAppProvider(File contextsDir) throws IOException
{
this();
- setMonitoredDir(Resource.newResource(contextsDir.toURI()));
+ setMonitoredDirResource(Resource.newResource(contextsDir.toURI()));
}
/**
@@ -303,7 +303,7 @@ public class OSGiAppProvider extends ScanningAppProvider implements AppProvider
{
try
{
- Resource monitoredDir = getMonitoredDir();
+ Resource monitoredDir = getMonitoredDirResource();
if (monitoredDir == null)
return null;
return monitoredDir.getFile();
@@ -324,7 +324,7 @@ public class OSGiAppProvider extends ScanningAppProvider implements AppProvider
{
try
{
- Resource monitoredDir = getMonitoredDir();
+ Resource monitoredDir = getMonitoredDirResource();
if (monitoredDir == null)
return null;
return monitoredDir.getFile().toURI().toString();
@@ -361,7 +361,7 @@ public class OSGiAppProvider extends ScanningAppProvider implements AppProvider
*/
public void setContextXmlDir(String contextsDir)
{
- setMonitoredDir(contextsDir);
+ setMonitoredDirName(contextsDir);
}
/**
diff --git a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/internal/serverfactory/ServerInstanceWrapper.java b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/internal/serverfactory/ServerInstanceWrapper.java
index 43e76704f2..bb89bfe488 100644
--- a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/internal/serverfactory/ServerInstanceWrapper.java
+++ b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/boot/internal/serverfactory/ServerInstanceWrapper.java
@@ -82,12 +82,12 @@ public class ServerInstanceWrapper {
public ServerInstanceWrapper(String managedServerName)
{
- _managedServerName = managedServerName;
+ _managedServerName = managedServerName;
}
public String getManagedServerName()
{
- return _managedServerName;
+ return _managedServerName;
}
/**
@@ -97,7 +97,7 @@ public class ServerInstanceWrapper {
*/
public ClassLoader getParentClassLoaderForWebapps()
{
- return _commonParentClassLoaderForWebapps;
+ return _commonParentClassLoaderForWebapps;
}
/**
@@ -105,7 +105,7 @@ public class ServerInstanceWrapper {
*/
public DeploymentManager getDeploymentManager()
{
- return _deploymentManager;
+ return _deploymentManager;
}
/**
@@ -113,19 +113,19 @@ public class ServerInstanceWrapper {
*/
public OSGiAppProvider getOSGiAppProvider()
{
- return _provider;
+ return _provider;
}
public Server getServer()
{
- return _server;
+ return _server;
}
public WebBundleDeployerHelper getWebBundleDeployerHelp()
{
- return _webBundleDeployerHelper;
+ return _webBundleDeployerHelper;
}
/**
@@ -133,25 +133,25 @@ public class ServerInstanceWrapper {
*/
public ContextHandlerCollection getContextHandlerCollection()
{
- return _ctxtHandler;
+ return _ctxtHandler;
}
- public void start(Server server, Dictionary props)
- {
- _server = server;
+ public void start(Server server, Dictionary props)
+ {
+ _server = server;
ClassLoader contextCl = Thread.currentThread().getContextClassLoader();
try
{
// passing this bundle's classloader as the context classlaoder
// makes sure there is access to all the jetty's bundles
ClassLoader libExtClassLoader = null;
- String sharedURLs = (String)props.get(OSGiServerConstants.MANAGED_JETTY_SHARED_LIB_FOLDER_URLS);
+ String sharedURLs = (String)props.get(OSGiServerConstants.MANAGED_JETTY_SHARED_LIB_FOLDER_URLS);
try
{
- List<File> shared = sharedURLs != null ? extractFiles(sharedURLs) : null;
- libExtClassLoader = LibExtClassLoaderHelper.createLibExtClassLoader(
- shared, null, server, JettyBootstrapActivator.class.getClassLoader());
+ List<File> shared = sharedURLs != null ? extractFiles(sharedURLs) : null;
+ libExtClassLoader = LibExtClassLoaderHelper.createLibExtClassLoader(
+ shared, null, server, JettyBootstrapActivator.class.getClassLoader());
}
catch (MalformedURLException e)
{
@@ -169,8 +169,8 @@ public class ServerInstanceWrapper {
{
URL[] jarsWithTlds = getJarsWithTlds();
_commonParentClassLoaderForWebapps = jarsWithTlds == null
- ? libExtClassLoader
- :new TldLocatableURLClassloader(libExtClassLoader,jarsWithTlds);
+ ? libExtClassLoader
+ :new TldLocatableURLClassloader(libExtClassLoader,jarsWithTlds);
}
catch (MalformedURLException e)
{
@@ -190,20 +190,20 @@ public class ServerInstanceWrapper {
}
_webBundleDeployerHelper = new WebBundleDeployerHelper(this);
}
-
-
- public void stop()
- {
- try {
- if (_server.isRunning())
- {
- _server.stop();
- }
- } catch (Exception e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
+
+
+ public void stop()
+ {
+ try {
+ if (_server.isRunning())
+ {
+ _server.stop();
+ }
+ } catch (Exception e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ }
/**
* TODO: right now only the jetty-jsp bundle is scanned for common taglibs.
@@ -232,7 +232,7 @@ public class ServerInstanceWrapper {
WebBundleDeployerHelper.staticInit();//that is not looking great.
for (WebappRegistrationCustomizer regCustomizer : WebBundleDeployerHelper.JSP_REGISTRATION_HELPERS)
{
- URL[] urls = regCustomizer.getJarsWithTlds(_provider, WebBundleDeployerHelper.BUNDLE_FILE_LOCATOR_HELPER);
+ URL[] urls = regCustomizer.getJarsWithTlds(_provider, WebBundleDeployerHelper.BUNDLE_FILE_LOCATOR_HELPER);
for (URL url : urls)
{
if (!res.contains(url))
@@ -249,12 +249,12 @@ public class ServerInstanceWrapper {
{
String jettyConfigurationUrls = (String) props.get(OSGiServerConstants.MANAGED_JETTY_XML_CONFIG_URLS);
List<URL> jettyConfigurations = jettyConfigurationUrls != null
- ? extractResources(jettyConfigurationUrls) : null;
- if (jettyConfigurations == null || jettyConfigurations.isEmpty())
- {
- return;
- }
- Map<String,Object> id_map = new HashMap<String,Object>();
+ ? extractResources(jettyConfigurationUrls) : null;
+ if (jettyConfigurations == null || jettyConfigurations.isEmpty())
+ {
+ return;
+ }
+ Map<String,Object> id_map = new HashMap<String,Object>();
id_map.put("Server",server);
Map<String,String> properties = new HashMap<String,String>();
Enumeration<Object> en = props.keys();
@@ -300,7 +300,7 @@ public class ServerInstanceWrapper {
}
finally
{
- IO.close(is);
+ IO.close(is);
}
}
@@ -336,17 +336,17 @@ public class ServerInstanceWrapper {
}
if (_provider == null)
{
- //create it on the fly with reasonable default values.
- try
- {
- _provider = new OSGiAppProvider();
- _provider.setMonitoredDir(
- Resource.newResource(getDefaultOSGiContextsHome(
- new File(System.getProperty("jetty.home"))).toURI()));
- } catch (IOException e) {
- e.printStackTrace();
- }
- _deploymentManager.addAppProvider(_provider);
+ //create it on the fly with reasonable default values.
+ try
+ {
+ _provider = new OSGiAppProvider();
+ _provider.setMonitoredDirResource(
+ Resource.newResource(getDefaultOSGiContextsHome(
+ new File(System.getProperty("jetty.home"))).toURI()));
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ _deploymentManager.addAppProvider(_provider);
}
}
@@ -380,7 +380,7 @@ public class ServerInstanceWrapper {
File getOSGiContextsHome()
{
- return _provider.getContextXmlDirAsFile();
+ return _provider.getContextXmlDirAsFile();
}
/**
@@ -388,22 +388,22 @@ public class ServerInstanceWrapper {
*/
private List<URL> extractResources(String propertyValue)
{
- StringTokenizer tokenizer = new StringTokenizer(propertyValue, ",;", false);
- List<URL> urls = new ArrayList<URL>();
- while (tokenizer.hasMoreTokens())
- {
- String tok = tokenizer.nextToken();
- try
- {
- urls.add(((DefaultFileLocatorHelper) WebBundleDeployerHelper
- .BUNDLE_FILE_LOCATOR_HELPER).getLocalURL(new URL(tok)));
- }
- catch (Throwable mfe)
- {
-
- }
- }
- return urls;
+ StringTokenizer tokenizer = new StringTokenizer(propertyValue, ",;", false);
+ List<URL> urls = new ArrayList<URL>();
+ while (tokenizer.hasMoreTokens())
+ {
+ String tok = tokenizer.nextToken();
+ try
+ {
+ urls.add(((DefaultFileLocatorHelper) WebBundleDeployerHelper
+ .BUNDLE_FILE_LOCATOR_HELPER).getLocalURL(new URL(tok)));
+ }
+ catch (Throwable mfe)
+ {
+
+ }
+ }
+ return urls;
}
/**
@@ -411,32 +411,32 @@ public class ServerInstanceWrapper {
*/
private List<File> extractFiles(String propertyValue)
{
- StringTokenizer tokenizer = new StringTokenizer(propertyValue, ",;", false);
- List<File> files = new ArrayList<File>();
- while (tokenizer.hasMoreTokens())
- {
- String tok = tokenizer.nextToken();
- try
- {
- URL url = new URL(tok);
- url = ((DefaultFileLocatorHelper) WebBundleDeployerHelper
- .BUNDLE_FILE_LOCATOR_HELPER).getFileURL(url);
- if (url.getProtocol().equals("file"))
- {
- Resource res = Resource.newResource(url);
- File folder = res.getFile();
- if (folder != null)
- {
- files.add(folder);
- }
- }
- }
- catch (Throwable mfe)
- {
-
- }
- }
- return files;
+ StringTokenizer tokenizer = new StringTokenizer(propertyValue, ",;", false);
+ List<File> files = new ArrayList<File>();
+ while (tokenizer.hasMoreTokens())
+ {
+ String tok = tokenizer.nextToken();
+ try
+ {
+ URL url = new URL(tok);
+ url = ((DefaultFileLocatorHelper) WebBundleDeployerHelper
+ .BUNDLE_FILE_LOCATOR_HELPER).getFileURL(url);
+ if (url.getProtocol().equals("file"))
+ {
+ Resource res = Resource.newResource(url);
+ File folder = res.getFile();
+ if (folder != null)
+ {
+ files.add(folder);
+ }
+ }
+ }
+ catch (Throwable mfe)
+ {
+
+ }
+ }
+ return files;
}
diff --git a/jetty-plus/src/main/config/etc/jetty-plus.xml b/jetty-plus/src/main/config/etc/jetty-plus.xml
index 89de5f865f..f259c9a2d1 100644
--- a/jetty-plus/src/main/config/etc/jetty-plus.xml
+++ b/jetty-plus/src/main/config/etc/jetty-plus.xml
@@ -83,7 +83,7 @@
<Call name="addAppProvider">
<Arg>
<New class="org.eclipse.jetty.deploy.providers.WebAppProvider">
- <Set name="monitoredDir"><Property name="jetty.home" default="." />/webapps-plus</Set>
+ <Set name="monitoredDirName"><Property name="jetty.home" default="." />/webapps-plus</Set>
<Set name="defaultsDescriptor"><Property name="jetty.home" default="."/>/etc/webdefault.xml</Set>
<Set name="scanInterval">5</Set>
<Set name="contextXmlDir"><Property name="jetty.home" default="." />/contexts</Set>

Back to the top