-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor Ident fetching logic and add H2 support
#deploy-testnav-ident-pool Revised methods for fetching and counting Idents in `DatabaseService` to improve query efficiency. Enabled H2 database console for local development and included sample data for testing. Adjusted security configurations to accommodate new endpoints and data sources.
- Loading branch information
Showing
8 changed files
with
106 additions
and
96 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
34 changes: 12 additions & 22 deletions
34
apps/testnav-ident-pool/src/main/resources/application-local.yml
This file contains 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
7 changes: 6 additions & 1 deletion
7
apps/testnav-ident-pool/src/main/resources/application-prod.yaml
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
|
||
spring: | ||
oauth2: | ||
tokenx: | ||
issuer-uri: ${TOKEN_X_ISSUER} | ||
jwk-set-uri: ${TOKEN_X_JWKS_URI} | ||
accepted-audience: ${TOKEN_X_CLIENT_ID} | ||
datasource: | ||
url: jdbc:postgresql://${NAIS_DATABASE_TESTNAV_IDENTPOOL_TESTNAV_IDENTPOOL_HOST}:${NAIS_DATABASE_TESTNAV_IDENTPOOL_TESTNAV_IDENTPOOL_PORT}/${NAIS_DATABASE_TESTNAV_IDENTPOOL_TESTNAV_IDENTPOOL_DATABASE}?user=${NAIS_DATABASE_TESTNAV_IDENTPOOL_TESTNAV_IDENTPOOL_USERNAME}&password=${NAIS_DATABASE_TESTNAV_IDENTPOOL_TESTNAV_IDENTPOOL_PASSWORD} | ||
driverClassName: org.postgresql.Driver | ||
hikari: | ||
maximum-pool-size: 3 | ||
minimum-idle: 1 | ||
minimum-idle: 1 |
This file contains 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
34 changes: 34 additions & 0 deletions
34
apps/testnav-ident-pool/src/main/resources/db/dev/h2-default-config.sql
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
|
||
insert into personidentifikator values(1,'FNR','13048226064','I_BRUK',false,'1982-04-13','KVINNE','TPS',false); | ||
insert into personidentifikator values(2,'FNR','03058225613','I_BRUK',false,'1982-05-03','KVINNE','TPS',false); | ||
insert into personidentifikator values(3,'FNR','25078225966','I_BRUK',false,'1982-07-25','MANN','TPS',false); | ||
insert into personidentifikator values(4,'FNR','16118225841','I_BRUK',false,'1982-11-16','KVINNE','TPS',false); | ||
insert into personidentifikator values(5,'FNR','30128225516','I_BRUK',false,'1982-12-30','MANN','TPS',false); | ||
insert into personidentifikator values(6,'FNR','03128225772','I_BRUK',false,'1982-12-03','MANN','TPS',false); | ||
insert into personidentifikator values(7,'FNR','22098225777','I_BRUK',false,'1982-09-22','MANN','TPS',false); | ||
insert into personidentifikator values(8,'FNR','26028225864','I_BRUK',false,'1982-02-26','KVINNE','TPS',false); | ||
insert into personidentifikator values(9,'FNR','09048225990','I_BRUK',false,'1982-04-09','MANN','TPS',false); | ||
insert into personidentifikator values(10,'FNR','14496205422','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(11,'FNR','14496208650','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(12,'FNR','14496201087','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(13,'FNR','14496209444','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(14,'FNR','14496205260','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(15,'FNR','14496209282','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(16,'FNR','14496200889','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(17,'FNR','14496201834','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(18,'FNR','14496202628','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(19,'FNR','14496206801','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(20,'FNR','14496201672','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(21,'FNR','14496204205','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(22,'FNR','14496203411','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(23,'FNR','14496202466','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(24,'FNR','14496205856','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(25,'FNR','14496204043','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(26,'FNR','14496208227','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(27,'FNR','14496206488','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(28,'FNR','14496203098','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(29,'FNR','14496205694','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(30,'FNR','14496207433','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
insert into personidentifikator values(31,'FNR','14496209010','LEDIG',false,'1962-09-14','KVINNE',null,true); | ||
|
||
commit; |