Skip to content

Commit

Permalink
Use Jetty Server
Browse files Browse the repository at this point in the history
Try Jetty 12 for better throughput
Forward webui urls to /index.html
  • Loading branch information
amvanbaren committed Jul 23, 2024
1 parent 63a9219 commit 25619c5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
11 changes: 7 additions & 4 deletions server/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ plugins {
id 'jacoco'
id 'nu.studer.jooq' version '8.2.1'
id 'de.undercouch.download' version '5.4.0'
id 'org.springframework.boot' version '3.1.0'
id 'org.springframework.boot' version '3.2.1'
id 'io.spring.dependency-management' version '1.1.0'
id 'io.gatling.gradle' version '3.9.5'
id 'java'
Expand Down Expand Up @@ -66,10 +66,13 @@ configurations {
}

dependencies {
implementation("org.springframework.boot:spring-boot-starter-web") {
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-tomcat'
implementation('org.springframework.boot:spring-boot-starter-web')
implementation 'org.springframework.boot:spring-boot-starter-jetty'
modules {
module("org.springframework.boot:spring-boot-starter-tomcat") {
replacedBy("org.springframework.boot:spring-boot-starter-jetty")
}
}
implementation "org.springframework.boot:spring-boot-starter-jetty"
implementation "org.springframework.boot:spring-boot-starter-validation"
implementation "org.springframework.boot:spring-boot-starter-jooq"
implementation "org.springframework.boot:spring-boot-starter-data-jpa"
Expand Down
3 changes: 1 addition & 2 deletions server/src/dev/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ server:
port: 8080
jetty:
threads:
max-queue-capacity: 1
max-http-post-size: 536870912
max-queue-capacity: 100

spring:
application:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public void addCorsMappings(CorsRegistry registry) {
@Override
public void addViewControllers(ViewControllerRegistry registry) {
for (var route : frontendRoutes) {
registry.addViewController(route).setViewName("forward:/");
registry.addViewController(route).setViewName("forward:/index.html");
}
}

Expand Down

0 comments on commit 25619c5

Please sign in to comment.