diff options
Diffstat (limited to 'language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java')
-rw-r--r-- | language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java b/language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java index a9017264..63088511 100644 --- a/language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java +++ b/language-web/src/main/java/org/eclipse/viatra/solver/language/web/ServerLauncher.java | |||
@@ -9,15 +9,10 @@ import java.net.InetSocketAddress; | |||
9 | import java.net.URI; | 9 | import java.net.URI; |
10 | import java.net.URISyntaxException; | 10 | import java.net.URISyntaxException; |
11 | 11 | ||
12 | import org.eclipse.jetty.annotations.AnnotationConfiguration; | ||
13 | import org.eclipse.jetty.server.Server; | 12 | import org.eclipse.jetty.server.Server; |
14 | import org.eclipse.jetty.util.log.Slf4jLog; | 13 | import org.eclipse.jetty.util.log.Slf4jLog; |
15 | import org.eclipse.jetty.util.resource.Resource; | 14 | import org.eclipse.jetty.util.resource.Resource; |
16 | import org.eclipse.jetty.webapp.Configuration; | ||
17 | import org.eclipse.jetty.webapp.MetaInfConfiguration; | ||
18 | import org.eclipse.jetty.webapp.WebAppContext; | 15 | import org.eclipse.jetty.webapp.WebAppContext; |
19 | import org.eclipse.jetty.webapp.WebInfConfiguration; | ||
20 | import org.eclipse.jetty.webapp.WebXmlConfiguration; | ||
21 | 16 | ||
22 | public class ServerLauncher { | 17 | public class ServerLauncher { |
23 | private static final Slf4jLog LOG = new Slf4jLog(ServerLauncher.class.getName()); | 18 | private static final Slf4jLog LOG = new Slf4jLog(ServerLauncher.class.getName()); |
@@ -30,9 +25,7 @@ public class ServerLauncher { | |||
30 | ctx.setBaseResource(baseResource); | 25 | ctx.setBaseResource(baseResource); |
31 | ctx.setWelcomeFiles(new String[] { "index.html" }); | 26 | ctx.setWelcomeFiles(new String[] { "index.html" }); |
32 | ctx.setContextPath("/"); | 27 | ctx.setContextPath("/"); |
33 | ctx.setConfigurations(new Configuration[] { new AnnotationConfiguration(), new WebXmlConfiguration(), | 28 | ctx.addServlet(ProblemServlet.class, "/xtext-service/*"); |
34 | new WebInfConfiguration(), new MetaInfConfiguration() }); | ||
35 | ctx.setAttribute(WebInfConfiguration.CONTAINER_JAR_PATTERN, ".*/build/classes/.*,.*\\.jar"); | ||
36 | ctx.setInitParameter("org.eclipse.jetty.servlet.Default.useFileMappedBuffer", "false"); | 29 | ctx.setInitParameter("org.eclipse.jetty.servlet.Default.useFileMappedBuffer", "false"); |
37 | server.setHandler(ctx); | 30 | server.setHandler(ctx); |
38 | } | 31 | } |