Commit 60689677 authored by Jyrgen Hannus's avatar Jyrgen Hannus
Browse files

TEIS-793: updated PostgreSQL dialect from v8.2 -> 10, added...

TEIS-793: updated PostgreSQL dialect from v8.2 -> 10, added teis.datasource.packages-to-scan configuration parameter to services, which use datasource (have database), added teis.reset-test-data.enabled flag for services, which use ResetTestDataListener to reset test data, removed ResetTestDataListener from services since it has been moved to commons library
parent faa0a026
package ee.sm.ti.teis.officials.test;
import ee.sm.ti.teis.servicecommon.util.TestDataImportService;
import lombok.AllArgsConstructor;
import lombok.RequiredArgsConstructor;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.context.annotation.Profile;
import org.springframework.stereotype.Service;
import static ee.sm.ti.teis.servicecommon.util.TestDataImportService.*;
@Service
@RequiredArgsConstructor
@Profile({"dev", "local", "test"})
public class ResetTestDataListener {
private final TestDataImportService testDataImportService;
@RabbitListener(queues = {"officials-service" + RESET_TEST_DATA_QUEUE_SUFFIX})
public void resetTestData(String providedMagicString) {
testDataImportService.resetTestData(providedMagicString);
}
}
......@@ -19,7 +19,7 @@ spring:
parameters:
db_app_username: ${DB_APP_USERNAME:teis}
jpa:
database-platform: org.hibernate.dialect.PostgreSQL82Dialect
database-platform: org.hibernate.dialect.PostgreSQL10Dialect
properties:
hibernate:
jdbc:
......@@ -45,6 +45,8 @@ management:
info.enabled: true
teis:
datasource:
packages-to-scan: ee.sm.ti.teis
system:
name: officials-service
test:
......@@ -60,3 +62,5 @@ teis:
cache:
queues: classifierItems, classifierDefinitions
reinitialize: OfficialsGroup, OfficialUser, Office
reset-test-data:
enabled: true
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment