From eccd280d711856de69e297462fa08ce27d6ce3b7 Mon Sep 17 00:00:00 2001 From: Tadgh Date: Mon, 15 Jun 2020 11:24:39 -0700 Subject: [PATCH] Fix test error --- hapi-fhir-jpaserver-base/pom.xml | 15 ++++++++++----- .../jpa/term/TermCodeSystemStorageSvcImpl.java | 6 +++++- hapi-fhir-jpaserver-batch/pom.xml | 3 +-- 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/hapi-fhir-jpaserver-base/pom.xml b/hapi-fhir-jpaserver-base/pom.xml index 0ce3f5c7f37..73ed63e66f7 100644 --- a/hapi-fhir-jpaserver-base/pom.xml +++ b/hapi-fhir-jpaserver-base/pom.xml @@ -153,11 +153,6 @@ - - ca.uhn.hapi.fhir - hapi-fhir-jpaserver-batch - ${project.version} - net.ttddyy @@ -388,6 +383,11 @@ org.springframework spring-websocket + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-batch + ${project.version} + @@ -604,6 +604,11 @@ org.jetbrains annotations + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-batch + ${project.version} + diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcImpl.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcImpl.java index 331c7aa2f24..3b98e8cd80c 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcImpl.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcImpl.java @@ -717,7 +717,11 @@ public class TermCodeSystemStorageSvcImpl implements ITermCodeSystemStorageSvc { ourLog.info(" * {} {} deleted ({}/{}) remaining - {}/sec - ETA: {}", count, theDescriptor, count, totalCount, sw.formatThroughput(count, TimeUnit.SECONDS), sw.getEstimatedTimeRemaining(count, totalCount)); } - theDao.flush(); + txTemplate.execute(t -> { + theDao.flush(); + return null; + }); + } diff --git a/hapi-fhir-jpaserver-batch/pom.xml b/hapi-fhir-jpaserver-batch/pom.xml index 6373f7a85c7..ed4e4eee954 100644 --- a/hapi-fhir-jpaserver-batch/pom.xml +++ b/hapi-fhir-jpaserver-batch/pom.xml @@ -29,7 +29,6 @@ org.springframework.data spring-data-jpa - ${spring_data_version} @@ -57,7 +56,7 @@ ca.uhn.hapi.fhir hapi-fhir-test-utilities - 5.1.0-SNAPSHOT + ${project.version} test