Skip to content

Commit 21ef115

Browse files
authored
Merge pull request #1779 from IBM/fix-stored-proc-updates
fix: postgres/db2 refresh of the stored procedure
2 parents 88fa91e + 41e95c7 commit 21ef115

File tree

1 file changed

+5
-1
lines changed
  • fhir-persistence-schema/src/main/java/com/ibm/fhir/schema/app

1 file changed

+5
-1
lines changed

fhir-persistence-schema/src/main/java/com/ibm/fhir/schema/app/Main.java

+5-1
Original file line numberDiff line numberDiff line change
@@ -374,6 +374,10 @@ protected void updateSchema() {
374374
if (!MULTITENANT_FEATURE_ENABLED.contains(dbType) && newDb ) {
375375
populateResourceTypeAndParameterNameTableEntries(null);
376376
}
377+
378+
// Let's refresh the procedures and functions.
379+
logger.info("Refreshing procedures and functions");
380+
updateProcedures();
377381
}
378382

379383
/**
@@ -475,7 +479,7 @@ protected void updateProcedures() {
475479
tx.setRollbackOnly();
476480
throw x;
477481
}
478-
c.commit();
482+
// Reminder: Don't fall into the trap, let the connectionPool and Transaction Management handle the transaction commit.
479483
} catch (SQLException x) {
480484
tx.setRollbackOnly();
481485
throw translator.translate(x);

0 commit comments

Comments
 (0)