/
springboot apps
springboot apps
Runtime error - Request header is too large
Basically add this to your applications.properties
file
server.max-http-request-header-size=20000
20000 can be greater or smaller
Application.properties file
Typical settings
spring.application.name=vat_calculator_service
server.max-http-request-header-size=20000
# H2 Database configuration
spring.datasource.url=jdbc:h2:mem:testdb
spring.datasource.driverClassName=org.h2.Driver
spring.datasource.username=sa
spring.datasource.password=password
spring.jpa.database-platform=org.hibernate.dialect.H2Dialect
spring.h2.console.enabled=true
spring.jpa.defer-datasource-initialization=true
spring.jpa.hibernate.ddl-auto=update
# Incase you are using MYSQL Database please comment/remove h2 database configuration above
# And uncomment below configuration
#spring.jpa.hibernate.ddl-auto=update
#spring.datasource.url=jdbc:mysql://localhost:3306/mydb
#spring.datasource.username=root
#spring.datasource.password=password
spring.jpa.show-sql = true
Using H2-DB
Spring Boot With H2 Database | Baeldung
maven build plugin
Use this plig to build your springboot application as a single jar with the mainclass path
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
<configuration>
<classifier>spring-boot</classifier>
<mainClass>
com.celestial.vatcsl.VatCalculatorServiceApplication
</mainClass>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>