From c00715ae4b6860f2832af172b3024d9be3ab5a16 Mon Sep 17 00:00:00 2001 From: Alexander Dudkin Date: Sat, 14 Sep 2024 21:31:26 +0300 Subject: [PATCH] refactor: change database name to camelCase --- .../dev/earlspilner/auth/security/SecurityConfig.java | 11 +++++++---- .../main/resources/application-postgresql.properties | 2 +- .../main/resources/application-postgresql.properties | 2 +- .../main/resources/application-postgresql.properties | 2 +- .../main/resources/application-postgresql.properties | 2 +- 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/library-api-authentication-server/src/main/java/dev/earlspilner/auth/security/SecurityConfig.java b/library-api-authentication-server/src/main/java/dev/earlspilner/auth/security/SecurityConfig.java index 88f14c1..0357736 100644 --- a/library-api-authentication-server/src/main/java/dev/earlspilner/auth/security/SecurityConfig.java +++ b/library-api-authentication-server/src/main/java/dev/earlspilner/auth/security/SecurityConfig.java @@ -27,12 +27,15 @@ public PasswordEncoder passwordEncoder() { @Bean public SecurityFilterChain filterChain(HttpSecurity http) throws Exception { - return http + // @formatter:off + http .csrf(AbstractHttpConfigurer::disable) - .authorizeHttpRequests(requests -> requests + .cors(AbstractHttpConfigurer::disable) + .authorizeHttpRequests((authz) -> authz .anyRequest().permitAll()) - .sessionManagement(session -> session.sessionCreationPolicy(STATELESS)) - .build(); + .sessionManagement(session -> session.sessionCreationPolicy(STATELESS)); + // @formatter:on + return http.build(); } @Bean diff --git a/library-api-books-service/src/main/resources/application-postgresql.properties b/library-api-books-service/src/main/resources/application-postgresql.properties index de4b61c..b1cc965 100644 --- a/library-api-books-service/src/main/resources/application-postgresql.properties +++ b/library-api-books-service/src/main/resources/application-postgresql.properties @@ -1,4 +1,4 @@ -spring.datasource.url=jdbc:postgresql://localhost:5432/library_books_db +spring.datasource.url=jdbc:postgresql://localhost:5432/libraryBooksDB spring.datasource.username=postgres spring.datasource.password=root spring.datasource.driver-class-name=org.postgresql.Driver diff --git a/library-api-library-service/src/main/resources/application-postgresql.properties b/library-api-library-service/src/main/resources/application-postgresql.properties index c51e4b9..25a9023 100644 --- a/library-api-library-service/src/main/resources/application-postgresql.properties +++ b/library-api-library-service/src/main/resources/application-postgresql.properties @@ -1,4 +1,4 @@ -spring.datasource.url=jdbc:postgresql://localhost:5432/library_db +spring.datasource.url=jdbc:postgresql://localhost:5432/libraryDB spring.datasource.username=postgres spring.datasource.password=root spring.datasource.driver-class-name=org.postgresql.Driver diff --git a/library-api-loan-service/src/main/resources/application-postgresql.properties b/library-api-loan-service/src/main/resources/application-postgresql.properties index eb78537..597d00f 100644 --- a/library-api-loan-service/src/main/resources/application-postgresql.properties +++ b/library-api-loan-service/src/main/resources/application-postgresql.properties @@ -1,4 +1,4 @@ -spring.datasource.url=jdbc:postgresql://localhost:5432/library_loans_db +spring.datasource.url=jdbc:postgresql://localhost:5432/libraryLoansDB spring.datasource.username=postgres spring.datasource.password=root spring.datasource.driver-class-name=org.postgresql.Driver diff --git a/library-api-users-service/src/main/resources/application-postgresql.properties b/library-api-users-service/src/main/resources/application-postgresql.properties index c6e6ef4..86bdb1e 100644 --- a/library-api-users-service/src/main/resources/application-postgresql.properties +++ b/library-api-users-service/src/main/resources/application-postgresql.properties @@ -1,4 +1,4 @@ -spring.datasource.url=jdbc:postgresql://localhost:5432/library_users_db +spring.datasource.url=jdbc:postgresql://localhost:5432/libraryUsersDB spring.datasource.username=postgres spring.datasource.password=root spring.datasource.driver-class-name=org.postgresql.Driver