Last active
September 4, 2024 20:04
-
-
Save bijay-shrestha/b0e019d5c60668c8c1a773ae3b880de7 to your computer and use it in GitHub Desktop.
application.properties for Spring boot
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# DATASOURCE (DataSourceAutoConfiguration & DataSourceProperties) | |
#spring.datasource.driverClassName=com.mysql.jdbc.Driver | |
#spring.datasource.url=jdbc:mysql://localhost/test | |
#spring.datasource.driverClassName=org.h2.Driver | |
#spring.datasource.url=jdbc:mysql://localhost:3306/test | |
#spring.datasource.username=user | |
#spring.datasource.password=user | |
#spring.jpa.database-platform=org.hibernate.dialect.MySQL5InnoDBDialect | |
#spring.jpa.database-platform=org.hibernate.dialect.MySQL5Dialect | |
### MySQL Datasource Properties | |
spring.datasource.driverClassName=com.mysql.jdbc.Driver | |
spring.datasource.url=jdbc:mysql://localhost:3306/x | |
spring.datasource.username=root | |
spring.datasource.password=pa$$w0rd | |
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect | |
spring.jpa.hibernate.ddl-auto=update | |
### Settings of Connection pool | |
spring.datasource.max-active=50 | |
spring.datasource.max-idle=8 | |
spring.datasource.min-idle=8 | |
spring.datasource.initial-size=10 | |
### Number of ms to wait before throwing an exception if no connection is available. | |
spring.datasource.max-wait=10000 | |
### JPA (JpaBaseConfiguration, HibernateJpaAutoConfiguration) | |
#spring.jpa.database-platform=org.hibernate.dialect.MySQLDialect | |
#spring.jpa.database-platform=org.hibernate.dialect.H2Dialect | |
spring.jpa.hibernate.ddl-auto=update | |
spring.jpa.show-sql=true | |
### H2 DataSource configuration | |
#spring.datasource.url=jdbc:h2:mem:testdb | |
#spring.datasource.driver-class-name=org.h2.Driver | |
#spring.datasource.username=sa | |
#spring.datasource.password= | |
### H2 JPA configuration | |
#spring.jpa.hibernate.ddl-auto=update | |
#spring.jpa.show-sql=true | |
### H2 Console configuration | |
#spring.h2.console.enabled=true # Enable the console. | |
#spring.h2.console.path=/h2-console # Path at which the console will be available. | |
###actuator | |
#management.endpoints.web.exposure.include=* | |
#management.endpoints.web.exposure.exclude=caches | |
#management.endpoints.health.show-details=always |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment