Update
This commit is contained in:
parent
0853654fd5
commit
206a24b5a4
3 changed files with 12 additions and 6 deletions
|
@ -28,8 +28,8 @@ dependencies {
|
||||||
// For DB
|
// For DB
|
||||||
implementation("io.quarkus:quarkus-hibernate-orm:3.6.4")
|
implementation("io.quarkus:quarkus-hibernate-orm:3.6.4")
|
||||||
implementation("io.quarkus:quarkus-hibernate-orm-panache-kotlin:3.6.4")
|
implementation("io.quarkus:quarkus-hibernate-orm-panache-kotlin:3.6.4")
|
||||||
implementation("io.quarkiverse.jdbc:quarkus-jdbc-sqlite:3.0.7")
|
|
||||||
implementation("io.quarkus:quarkus-hibernate-validator:3.6.4")
|
implementation("io.quarkus:quarkus-hibernate-validator:3.6.4")
|
||||||
|
implementation("io.quarkiverse.jdbc:quarkus-jdbc-sqlite:3.0.7")
|
||||||
|
|
||||||
developmentOnly("org.springframework.boot:spring-boot-devtools")
|
developmentOnly("org.springframework.boot:spring-boot-devtools")
|
||||||
testImplementation("org.springframework.boot:spring-boot-starter-test")
|
testImplementation("org.springframework.boot:spring-boot-starter-test")
|
||||||
|
|
|
@ -10,7 +10,7 @@ import org.springframework.web.bind.annotation.*
|
||||||
class UsersController {
|
class UsersController {
|
||||||
@GetMapping("/users")
|
@GetMapping("/users")
|
||||||
fun index(): List<User> {
|
fun index(): List<User> {
|
||||||
return User.findAll().list()
|
return User.listAll()
|
||||||
}
|
}
|
||||||
|
|
||||||
@GetMapping("/users/{id}")
|
@GetMapping("/users/{id}")
|
||||||
|
|
|
@ -1,8 +1,14 @@
|
||||||
# configure your datasource
|
# configure your datasource
|
||||||
quarkus.datasource.db-kind=sqlite
|
quarkus.datasource.db-kind=sqlite
|
||||||
quarkus.datasource.username=
|
quarkus.datasource.jdbc.url=jdbc:sqlite::memory:
|
||||||
quarkus.datasource.password=
|
|
||||||
quarkus.datasource.jdbc.url=jdbc:sqlite:///test.db
|
#%prod.quarkus.datasource.db-kind=postgresql
|
||||||
|
#%prod.quarkus.datasource.username=quarkus_test
|
||||||
|
#%prod.quarkus.datasource.password=quarkus_test
|
||||||
|
#%prod.quarkus.datasource.jdbc.url=jdbc:postgresql://localhost/quarkus_test
|
||||||
|
#%prod.quarkus.datasource.jdbc.max-size=8
|
||||||
|
#%prod.quarkus.datasource.jdbc.min-size=2
|
||||||
|
|
||||||
# drop and create the database at startup (use `update` to only update the schema)
|
# drop and create the database at startup (use `update` to only update the schema)
|
||||||
quarkus.hibernate-orm.database.generation=update
|
quarkus.hibernate-orm.database.generation=update
|
||||||
|
quarkus.hibernate-orm.log.sql=true
|
Loading…
Reference in a new issue