Backport 5722 into 7.0.1 (#5729)

* Bugfix: removed reference to public schema in raw sql (#5722)

* Bugfix: removed reference to public schema in raw sql

* Add attribution for #5722

---------

Co-authored-by: James Agnew <jamesagnew@gmail.com>

* Add backport tag

* Build fix

---------

Co-authored-by: pano-smals <135063507+pano-smals@users.noreply.github.com>
This commit is contained in:
James Agnew 2024-02-22 16:06:42 -05:00 committed by GitHub
parent 28d88b1462
commit e71efe5029
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 13 additions and 3 deletions

View File

@ -137,7 +137,6 @@ public enum VersionEnum {
V7_0_0,
V7_0_1,
V7_0_1,
V7_1_0,
V7_2_0;

View File

@ -0,0 +1,7 @@
---
type: fix
issue: 5722
backport: 7.0.1
title: "An incorrect migration script caused a failure when upgrading to HAPI FHIR 7.0.0 on
PostgreSQL if the database was not in the `public` schema. Thanks to GitHub
user @pano-smals for the contribution!"

View File

@ -183,7 +183,7 @@ public class HapiFhirJpaMigrationTasks extends BaseMigrationTasks<VersionEnum> {
{
version.executeRawSql(
"20231212.1",
"CREATE INDEX CONCURRENTLY idx_sp_string_hash_nrm_pattern_ops ON public.hfj_spidx_string USING btree (hash_norm_prefix, sp_value_normalized varchar_pattern_ops, res_id, partition_id)")
"CREATE INDEX CONCURRENTLY idx_sp_string_hash_nrm_pattern_ops ON hfj_spidx_string USING btree (hash_norm_prefix, sp_value_normalized varchar_pattern_ops, res_id, partition_id)")
.setTransactional(false)
.onlyAppliesToPlatforms(DriverTypeEnum.POSTGRES_9_4)
.onlyIf(
@ -197,7 +197,7 @@ public class HapiFhirJpaMigrationTasks extends BaseMigrationTasks<VersionEnum> {
"Index idx_sp_string_hash_nrm_pattern_ops already exists");
version.executeRawSql(
"20231212.2",
"CREATE UNIQUE INDEX CONCURRENTLY idx_sp_uri_hash_identity_pattern_ops ON public.hfj_spidx_uri USING btree (hash_identity, sp_uri varchar_pattern_ops, res_id, partition_id)")
"CREATE UNIQUE INDEX CONCURRENTLY idx_sp_uri_hash_identity_pattern_ops ON hfj_spidx_uri USING btree (hash_identity, sp_uri varchar_pattern_ops, res_id, partition_id)")
.setTransactional(false)
.onlyAppliesToPlatforms(DriverTypeEnum.POSTGRES_9_4)
.onlyIf(

View File

@ -887,6 +887,10 @@
<name>Max Bureck</name>
<organization>Fraunhofer FOKUS</organization>
</developer>
<developer>
<id>pano-smals</id>
<name>pano-smals</name>
</developer>
</developers>
<licenses>