374174 Consistent mbean names
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@3269 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
parent
694db8e81e
commit
09bb70c161
|
@ -13,6 +13,7 @@ jetty-7.4.2-SNAPSHOT
|
|||
+ 346614 HttpConnection.handle() spins in case of SSL truncation attacks
|
||||
+ 346764 OrderedGroupBinding deployment binding
|
||||
+ 347137 Allow SSL renegotiations by default in HttpClient
|
||||
+ 374174 Consistent mbean names
|
||||
+ JETTY-1146 Encode jsessionid in sendRedirect
|
||||
+ JETTY-1342 Recreate selector if wakeup throws JVM bug
|
||||
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
|
||||
package org.eclipse.jetty.server.handler.jmx;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
||||
import org.eclipse.jetty.jmx.ObjectMBean;
|
||||
|
@ -92,7 +91,7 @@ public class AbstractHandlerMBean extends ObjectMBean
|
|||
|
||||
if (context.getContextPath()!=null && context.getContextPath().length()>0)
|
||||
{
|
||||
int idx = context.getContextPath().lastIndexOf(File.separator);
|
||||
int idx = context.getContextPath().lastIndexOf('/');
|
||||
name = idx < 0 ? context.getContextPath() : context.getContextPath().substring(++idx);
|
||||
if (name==null || name.length()==0)
|
||||
name= "ROOT";
|
||||
|
|
|
@ -29,11 +29,13 @@ import org.eclipse.jetty.server.NCSARequestLog;
|
|||
import org.eclipse.jetty.server.Request;
|
||||
import org.eclipse.jetty.server.Server;
|
||||
import org.eclipse.jetty.server.bio.SocketConnector;
|
||||
import org.eclipse.jetty.server.handler.ContextHandler;
|
||||
import org.eclipse.jetty.server.handler.ContextHandlerCollection;
|
||||
import org.eclipse.jetty.server.handler.DefaultHandler;
|
||||
import org.eclipse.jetty.server.handler.HandlerCollection;
|
||||
import org.eclipse.jetty.server.handler.HandlerWrapper;
|
||||
import org.eclipse.jetty.server.handler.RequestLogHandler;
|
||||
import org.eclipse.jetty.server.handler.ResourceHandler;
|
||||
import org.eclipse.jetty.server.nio.BlockingChannelConnector;
|
||||
import org.eclipse.jetty.server.nio.SelectChannelConnector;
|
||||
import org.eclipse.jetty.server.session.HashSessionManager;
|
||||
|
@ -149,6 +151,12 @@ public class TestServer
|
|||
|
||||
contexts.addHandler(webapp);
|
||||
|
||||
ContextHandler srcroot = new ContextHandler();
|
||||
srcroot.setResourceBase(".");
|
||||
srcroot.setHandler(new ResourceHandler());
|
||||
srcroot.setContextPath("/src");
|
||||
contexts.addHandler(srcroot);
|
||||
|
||||
server.start();
|
||||
server.join();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue