Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/i-m-hossain/java-rest-service
https://github.com/i-m-hossain/java-rest-service
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/i-m-hossain/java-rest-service
- Owner: i-m-hossain
- Created: 2023-12-02T19:02:07.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-17T09:00:41.000Z (about 1 year ago)
- Last Synced: 2024-10-15T07:27:59.701Z (3 months ago)
- Language: Java
- Size: 83 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
## Hibernate:
Hibernate is the implementation of jpa. (Jakarta Persistence API)## Spring JPA:
We can directly talk to a database using the model attributes and Entity manager methods. Here we don't need to instruct explicitly to use sql queries. The model attributes directly map into database columns.
## Spring JDBC
Spring JDBC allows us to run raw sql queries in our Spring Boot application## H2 console
- To Access H2 database: [h2-console-link](http://localhost:8080/h2-console)
- To make the connection string static ``spring.datasource.url=jdbc:h2:mem:testdb`` property added in ``application.properties``## Run a command at startup:
To run any command at the application startup, ``CommandLineRunner`` interface needs to be implemented.