All checks were successful
/ build (push) Successful in 1m13s
Instead of being forced to use a table scan it now uses the available indexes for direct access to the correct rows. Fixes #15 Old `ANALYZE` output ``` *************************** 1. row *************************** id: 1 select_type: SIMPLE table: v2_oauth2_authorization type: ALL possible_keys: I_authorization_code_token,I_authorization_access_token key: NULL key_len: NULL ref: NULL rows: 7473 r_rows: 11669.00 filtered: 100.00 r_filtered: 0.00 Extra: Using where ``` and after indexes were added ``` *************************** 1. row *************************** id: 1 select_type: SIMPLE table: v2_oauth2_authorization type: index_merge possible_keys: I_authorization_code_token,I_authorization_access_token,I_authorization_device_code_token,I_authorization_state,I_authorization_user_code_token,I_authorization_refresh_token,I_authorization_id_token key: I_authorization_state,I_authorization_code_token,I_authorization_device_code_token,I_authorization_user_code_token,I_authorization_access_token,I_authorization_refresh_token,I_authorization_id_token key_len: 3075,3075,3075,3075,3075,3075,3075 ref: NULL rows: 7 r_rows: 0.00 filtered: 100.00 r_filtered: 100.00 Extra: Using sort_union(I_authorization_state,I_authorization_code_token,I_authorization_device_code_token,I_authorization_user_code_token,I_authorization_access_token,I_authorization_refresh_token,I_authorization_id_token); Using where ```
Using as an embedded Docker Compose service
services:
oauth2:
image: gitea.dsv.su.se/dmc/oauth2:latest
ports:
- "<host_port>:8080"
environment:
CLIENT_ID=awesome-app
CLIENT_SECRET=p4ssw0rd
CLIENT_REDIRECT_URI=http://localhost/oauth2/callback
Development
Prerequisites
- JDK 17 (or later)
- Docker
- Docker compose 2.24.0 (or later)
Run mvnw spring-boot:run to start the application.
If running via IntelliJ or some other means make sure the "dev" Spring profile is activated.
You may have to run mvnw compile to generate any necessary files.
The application will be available at http://localhost:8080
Description
Languages
Java
99%
Dockerfile
0.9%
CSS
0.1%