This commit is contained in:
@@ -118,8 +118,7 @@ public abstract class BasedHttpServlet extends HttpServlet {
|
|||||||
throw new IOException(this.getClass().getName() + " not found method for URI(" + request.getRequestURI() + ")");
|
throw new IOException(this.getClass().getName() + " not found method for URI(" + request.getRequestURI() + ")");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
public final void preInit(HttpContext context, AnyValue config) {
|
||||||
public void init(HttpContext context, AnyValue config) {
|
|
||||||
String path = _prefix == null ? "" : _prefix;
|
String path = _prefix == null ? "" : _prefix;
|
||||||
WebServlet ws = this.getClass().getAnnotation(WebServlet.class);
|
WebServlet ws = this.getClass().getAnnotation(WebServlet.class);
|
||||||
if (ws != null && !ws.repair()) path = "";
|
if (ws != null && !ws.repair()) path = "";
|
||||||
|
|||||||
@@ -36,7 +36,11 @@ public final class HttpPrepareServlet extends PrepareServlet<HttpContext, HttpRe
|
|||||||
@Override
|
@Override
|
||||||
public void init(HttpContext context, AnyValue config) {
|
public void init(HttpContext context, AnyValue config) {
|
||||||
this.servlets.stream().forEach(s -> {
|
this.servlets.stream().forEach(s -> {
|
||||||
if (s instanceof WebSocketServlet) ((WebSocketServlet) s).preInit(context, s._conf);
|
if (s instanceof WebSocketServlet) {
|
||||||
|
((WebSocketServlet) s).preInit(context, s._conf);
|
||||||
|
} else if (s instanceof BasedHttpServlet) {
|
||||||
|
((BasedHttpServlet) s).preInit(context, s._conf);
|
||||||
|
}
|
||||||
s.init(context, s._conf);
|
s.init(context, s._conf);
|
||||||
});
|
});
|
||||||
final WatchFactory watch = context.getWatchFactory();
|
final WatchFactory watch = context.getWatchFactory();
|
||||||
|
|||||||
Reference in New Issue
Block a user