Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema defined for fhir in persistence.json not used correctly when running Docker fhir-persistence-schema #1795

Closed
holger-stenzhorn opened this issue Dec 4, 2020 · 6 comments · Fixed by #1799
Assignees
Labels
bug Something isn't working cloud portability
Milestone

Comments

@holger-stenzhorn
Copy link
Contributor

Describe the bug
The schema defined for fhir in persistence.json is not used correctly when running Docker fhir-persistence-schema.

To Reproduce

  1. Define the following persistence.json where schema for fhir is set to the value somefhirschema, i.e. to some value other than fhirdata:
    {
        "persistence": [
            {
                "db":  {
                    "host": "postgres",
                    "port": "5432",
                    "database": "fhir",
                    "user": "fhir",
                    "password": "change-password",
                    "type": "postgresql"
                },
                "schema": {
                    "fhir": "somefhirschema"
                },
                "behavior": "onboard"
            }
        ]
    }
  2. Run the Docker image/container fhir-persistence-schema:
    holger@homer:~$ ENV_TOOL_INPUT=$(cat persistence.json)
    holger@homer:~$ docker run --env ENV_TOOL_INPUT=$ENV_TOOL_INPUT ibmcom/ibm-fhir-schematool:4.5.2                                                                        
  3. See the result:
       base64: invalid input
    The tool behavior being executed is onboard
    run.sh - [INFO]: 2020-12-04_20:10:06 - Starting the onboard behavior
    run.sh - [INFO]: 2020-12-04_20:10:06 - Activating Network Path Connection...
    run.sh - [INFO]: 2020-12-04_20:10:06 - [NETWORK_PATH_CHECK] - SUCCESS - Connected to the database - postgres:5432
    run.sh - [INFO]: 2020-12-04_20:10:06 - creating the schema
    + /opt/java/openjdk/bin/java -jar /opt/schematool/fhir-persistence-schema-4.5.2-cli.jar --prop db.host=postgres --prop db.port=5432 --prop db.database=fhir --prop user=fhir --prop password=change-password --db-type postgresql --create-schemas --pool-size 2
    + tee out.log
    2020-12-04 20:10:07.483 00000001    INFO   com.ibm.fhir.schema.app.Main Opening connection to: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:07.860 00000001    INFO s.postgresql.PostgreSqlAdapter The schema 'FHIR_ADMIN' is created or already exists
    2020-12-04 20:10:07.863 00000001    INFO s.postgresql.PostgreSqlAdapter The schema 'FHIRDATA' is created or already exists
    2020-12-04 20:10:07.867 00000001    INFO s.postgresql.PostgreSqlAdapter The schema 'FHIR_OAUTH' is created or already exists
    2020-12-04 20:10:07.870 00000001    INFO s.postgresql.PostgreSqlAdapter The schema 'FHIR_JBATCH' is created or already exists
    2020-12-04 20:10:07.876 00000001    INFO   com.ibm.fhir.schema.app.Main Processing took:   0.435 s
    2020-12-04 20:10:07.878 00000001    INFO   com.ibm.fhir.schema.app.Main SCHEMA CHANGE: OK
    + set +x
    run.sh - [INFO]: 2020-12-04_20:10:07 - done creating the schema
    + /opt/java/openjdk/bin/java -jar /opt/schematool/fhir-persistence-schema-4.5.2-cli.jar --prop db.host=postgres --prop db.port=5432 --prop db.database=fhir --prop user=fhir --prop password=change-password --db-type postgresql --schema-name somefhirschema --update-schema --pool-size 1
    + tee out.log
    2020-12-04 20:10:09.406 00000001    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:09.844 00000001    INFO   com.ibm.fhir.schema.app.Main Collecting model update tasks
    2020-12-04 20:10:10.090 00000001    INFO   com.ibm.fhir.schema.app.Main Starting model updates
    2020-12-04 20:10:10.097 00000017    INFO ase.utils.model.DatabaseObject Applying change [v1]: TABLESPACE:FHIR_TS:1
    2020-12-04 20:10:10.099 00000017 WARNING s.postgresql.PostgreSqlAdapter [ONCE] Create tablespace not supported in PostgreSql
    2020-12-04 20:10:10.110 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLESPACE:FHIR_TS:1
    2020-12-04 20:10:10.115 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: SEQUENCE:FHIR_ADMIN.TENANT_SEQUENCE:1
    2020-12-04 20:10:10.117 00000017 WARNING s.postgresql.PostgreSqlAdapter [ONCE] PostgreSql does not support CREATE VARIABLE for: SV_TENANT_ID
    2020-12-04 20:10:10.122 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: VARIABLE:FHIR_ADMIN.SV_TENANT_ID:1
    2020-12-04 20:10:10.129 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] SEQUENCE:SOMEFHIRSCHEMA.FHIR_SEQUENCE:1
    2020-12-04 20:10:10.131 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.134 00000017  SEVERE .fhir.task.core.impl.TaskGroup SEQUENCE:SOMEFHIRSCHEMA.FHIR_SEQUENCE:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createSequence(PostgreSqlAdapter.java:204)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:48)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:60)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.144 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: SEQUENCE:SOMEFHIRSCHEMA.FHIR_SEQUENCE:1
    2020-12-04 20:10:10.146 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.158 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] SEQUENCE:SOMEFHIRSCHEMA.FHIR_REF_SEQUENCE:1
    2020-12-04 20:10:10.159 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.162 00000017  SEVERE .fhir.task.core.impl.TaskGroup SEQUENCE:SOMEFHIRSCHEMA.FHIR_REF_SEQUENCE:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createSequence(PostgreSqlAdapter.java:204)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:48)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:60)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.172 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: SEQUENCE:SOMEFHIRSCHEMA.FHIR_REF_SEQUENCE:1
    2020-12-04 20:10:10.175 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.191 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] SEQUENCE:SOMEFHIRSCHEMA.REFERENCES_SEQUENCE:1
    2020-12-04 20:10:10.194 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.197 00000017  SEVERE .fhir.task.core.impl.TaskGroup SEQUENCE:SOMEFHIRSCHEMA.REFERENCES_SEQUENCE:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createSequence(PostgreSqlAdapter.java:204)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:48)
    	at com.ibm.fhir.database.utils.model.Sequence.apply(Sequence.java:60)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.206 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: SEQUENCE:SOMEFHIRSCHEMA.REFERENCES_SEQUENCE:1
    2020-12-04 20:10:10.209 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.245 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_OAUTH.OAUTH20CACHE:1
    2020-12-04 20:10:10.258 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_OAUTH.OAUTH20CLIENTCONFIG:1
    2020-12-04 20:10:10.268 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_OAUTH.OAUTH20CONSENTCACHE:1
    2020-12-04 20:10:10.283 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.JOBINSTANCE:1
    2020-12-04 20:10:10.295 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_ADMIN.TENANTS:1
    2020-12-04 20:10:10.298 00000017 WARNING s.postgresql.PostgreSqlAdapter [ONCE] PostgreSql does support not multi-tenancy: CODE_SYSTEMS
    2020-12-04 20:10:10.320 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] TABLE:SOMEFHIRSCHEMA.CODE_SYSTEMS:1
    2020-12-04 20:10:10.322 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.325 00000017  SEVERE .fhir.task.core.impl.TaskGroup TABLE:SOMEFHIRSCHEMA.CODE_SYSTEMS:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createTable(PostgreSqlAdapter.java:101)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:117)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:145)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.334 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: TABLE:SOMEFHIRSCHEMA.CODE_SYSTEMS:1
    2020-12-04 20:10:10.336 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.355 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] TABLE:SOMEFHIRSCHEMA.PARAMETER_NAMES:1
    2020-12-04 20:10:10.358 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.363 00000017  SEVERE .fhir.task.core.impl.TaskGroup TABLE:SOMEFHIRSCHEMA.PARAMETER_NAMES:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createTable(PostgreSqlAdapter.java:101)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:117)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:145)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.373 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: TABLE:SOMEFHIRSCHEMA.PARAMETER_NAMES:1
    2020-12-04 20:10:10.376 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.392 00000017  SEVERE atabase.utils.model.BaseObject [FAILED] TABLE:SOMEFHIRSCHEMA.RESOURCE_TYPES:1
    2020-12-04 20:10:10.395 00000017 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.401 00000017  SEVERE .fhir.task.core.impl.TaskGroup TABLE:SOMEFHIRSCHEMA.RESOURCE_TYPES:1
    
    org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    com.ibm.fhir.database.utils.api.DataAccessException: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:104)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:227)
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlAdapter.createTable(PostgreSqlAdapter.java:101)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:117)
    	at com.ibm.fhir.database.utils.model.Table.apply(Table.java:145)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyVersion(BaseObject.java:263)
    	at com.ibm.fhir.database.utils.model.BaseObject.applyTx(BaseObject.java:214)
    	at com.ibm.fhir.database.utils.model.BaseObject.lambda$collect$0(BaseObject.java:201)
    	at com.ibm.fhir.database.utils.model.BaseObject$$Lambda$89/0x00000000cc7ee230.run(Unknown Source)
    	at com.ibm.fhir.task.core.impl.TaskGroup.runTask(TaskGroup.java:137)
    	at com.ibm.fhir.task.core.impl.TaskGroup.lambda$runTask$0(TaskGroup.java:129)
    	at com.ibm.fhir.task.core.impl.TaskGroup$$Lambda$90/0x00000000cc66dd10.run(Unknown Source)
    	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.base/java.lang.Thread.run(Unknown Source)
    Caused by: org.postgresql.util.PSQLException: ERROR: schema "somefhirschema" does not exist
      Position: 14
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:310)
    	at org.postgresql.jdbc.PgStatement.executeCachedSql(PgStatement.java:296)
    	at org.postgresql.jdbc.PgStatement.executeWithFlags(PgStatement.java:273)
    	at org.postgresql.jdbc.PgStatement.executeUpdate(PgStatement.java:247)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:246)
    	at com.ibm.fhir.database.utils.common.CommonDatabaseAdapter.runStatement(CommonDatabaseAdapter.java:225)
    	... 15 more
    2020-12-04 20:10:10.415 00000017    INFO hir.task.core.impl.TaskManager Task failed callback for taskId: TABLE:SOMEFHIRSCHEMA.RESOURCE_TYPES:1
    2020-12-04 20:10:10.418 00000017    INFO .common.JdbcConnectionProvider Opening connection to database: jdbc:postgresql://postgres:5432/fhir
    2020-12-04 20:10:10.456 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.JOBEXECUTION:1
    2020-12-04 20:10:10.470 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.GROUPASSOCIATION:1
    2020-12-04 20:10:10.496 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_ADMIN.TENANT_KEYS:1
    2020-12-04 20:10:10.511 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.JOBPARAMETER:1
    2020-12-04 20:10:10.538 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.STEPTHREADEXECUTION:1
    2020-12-04 20:10:10.541 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: NOP:FHIR_ADMIN.allAdminTablesComplete:0
    2020-12-04 20:10:10.576 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.STEPTHREADINSTANCE:1
    2020-12-04 20:10:10.601 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: TABLE:FHIR_JBATCH.REMOTABLEPARTITION:1
    2020-12-04 20:10:10.610 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: PROCEDURE:FHIR_ADMIN.SET_TENANT:2
    2020-12-04 20:10:10.613 00000017    INFO hir.task.core.impl.TaskManager Task complete callback for taskId: NOP:FHIR_ADMIN.adminSchemaComplete:0
    2020-12-04 20:10:10.617 00000001  SEVERE   com.ibm.fhir.schema.app.Main List of failed task groups: SEQUENCE:SOMEFHIRSCHEMA.FHIR_SEQUENCE:1,SEQUENCE:SOMEFHIRSCHEMA.FHIR_REF_SEQUENCE:1,SEQUENCE:SOMEFHIRSCHEMA.REFERENCES_SEQUENCE:1,TABLE:SOMEFHIRSCHEMA.CODE_SYSTEMS:1,TABLE:SOMEFHIRSCHEMA.PARAMETER_NAMES:1,TABLE:SOMEFHIRSCHEMA.RESOURCE_TYPES:1
    2020-12-04 20:10:10.620 00000001    INFO   com.ibm.fhir.schema.app.Main tenantId [default] is being pre-populated with lookup table data.
    2020-12-04 20:10:10.626 00000001 WARNING ls.pool.PoolConnectionProvider Rolling back transaction
    2020-12-04 20:10:10.629 00000001  SEVERE   com.ibm.fhir.schema.app.Main schema tool failed
    
    org.postgresql.util.PSQLException: ERROR: relation "somefhirschema.resource_types" does not exist
      Position: 45
    com.ibm.fhir.database.utils.api.UndefinedNameException: org.postgresql.util.PSQLException: ERROR: relation "somefhirschema.resource_types" does not exist
      Position: 45
    	at com.ibm.fhir.database.utils.postgresql.PostgreSqlTranslator.translate(PostgreSqlTranslator.java:100)
    	at com.ibm.fhir.schema.control.PopulateResourceTypes.run(PopulateResourceTypes.java:69)
    	at com.ibm.fhir.schema.app.Main.populateResourceTypeAndParameterNameTableEntries(Main.java:387)
    	at com.ibm.fhir.schema.app.Main.updateSchema(Main.java:362)
    	at com.ibm.fhir.schema.app.Main.process(Main.java:1436)
    	at com.ibm.fhir.schema.app.Main.main(Main.java:1513)
    Caused by: org.postgresql.util.PSQLException: ERROR: relation "somefhirschema.resource_types" does not exist
      Position: 45
    	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2533)
    	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2268)
    	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:313)
    	at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:448)
    	at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:369)
    	at org.postgresql.jdbc.PgPreparedStatement.executeWithFlags(PgPreparedStatement.java:159)
    	at org.postgresql.jdbc.PgPreparedStatement.execute(PgPreparedStatement.java:148)
    	at com.ibm.fhir.schema.control.PopulateResourceTypes.run(PopulateResourceTypes.java:61)
    	... 4 more
    2020-12-04 20:10:10.635 00000001  SEVERE   com.ibm.fhir.schema.app.Main SCHEMA CHANGE: RUNTIME ERROR

Expected behavior
n/a

Additional context
If one looks at the above log one can see that in the commands like...
+ /opt/java/openjdk/bin/java -jar /opt/schematool/fhir-persistence-schema-4.5.2-cli.jar --prop db.host=postgres --prop db.port=5432 --prop db.database=fhir --prop user=fhir --prop password=change-password --db-type postgresql --create-schemas --pool-size 2
...the property for schema.name.fhir is missing.

So to fix this issue the commands should contain that property and read something like ...
+ /opt/java/openjdk/bin/java -jar /opt/schematool/fhir-persistence-schema-4.5.2-cli.jar --prop db.host=postgres --prop db.port=5432 --prop db.database=fhir --prop schema.name.fhir=somefhirschema --prop user=fhir --prop password=change-password --db-type postgresql --create-schemas --pool-size 2

@holger-stenzhorn holger-stenzhorn added the bug Something isn't working label Dec 4, 2020
@prb112 prb112 self-assigned this Dec 4, 2020
@prb112
Copy link
Contributor

prb112 commented Dec 4, 2020

Thanks, I'll look at it early Monday

@holger-stenzhorn
Copy link
Contributor Author

Just for completeness: The same error occurs also if not persistence.json but the command line parameters are used:

docker run --network ibm-fhir-server-postgres-docker-compose_default ibmcom/ibm-fhir-schematool:4.5.2 --tool.behavior=onboard --db.type=postgresql --db.host=postgres --db.port=5432 --db.database=fhir --schema.name.fhir=somefhirschema --user=fhir --password=change-password

@prb112
Copy link
Contributor

prb112 commented Dec 4, 2020

Right - it's in create-schemas - I only specified the defaults, I'll change this on monday

@prb112
Copy link
Contributor

prb112 commented Dec 4, 2020

p.s. thank you

@prb112 prb112 added this to the Sprint 21 milestone Dec 5, 2020
prb112 added a commit that referenced this issue Dec 5, 2020
running Docker `fhir-persistence-schema`
#1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>
prb112 added a commit that referenced this issue Dec 7, 2020
Signed-off-by: Paul Bastide <pbastide@us.ibm.com>
prb112 added a commit that referenced this issue Dec 7, 2020
Signed-off-by: Paul Bastide <pbastide@us.ibm.com>
prb112 added a commit that referenced this issue Dec 7, 2020
Signed-off-by: Paul Bastide <pbastide@us.ibm.com>
@prb112
Copy link
Contributor

prb112 commented Dec 7, 2020

Added a test for this one in #1799
Had to add a couple of spots for schema_name support for oauth and jbatch and fhirdata

@lmsurpre lmsurpre reopened this Dec 8, 2020
JohnTimm added a commit that referenced this issue Dec 15, 2020
* Enable OpenLiberty override the fhiropenapi functionality #1760

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Issue #1780 - add compartment search/search parameter config section

Signed-off-by: Mike Schroeder <mschroed@us.ibm.com>

* issue #1789 refresh-tenants does not handle Db2 multi-tenant/multi-schema scenarios

Signed-off-by: Robin Arnold <robin.arnold23@ibm.com>

* Invalid SQL object name `--pool-size` exception when running Docker
`fhir-persistence-schema` on PostgreSQL #1797

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Misleading error messages when using command line parameters and not
`persistence.json` for Docker `fhir-persistence-schema` #1796

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Schema defined for `fhir` in `persistence.json` not used correctly when
running Docker `fhir-persistence-schema`
#1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update must gather to include open shift details

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* use the fhiruser password from helm (set by overrides from KeyProtect)

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Fix the definition for List-identifier search

A workaround for https://jira.hl7.org/browse/FHIR-29937

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Fix up the Must Gather

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* IBM FHIR Server audit does not log bundles correctly. #1803

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update documentation for the mustgather

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: per code review changed the compare, and added an additional ignore
for the metadata endpoints

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Update fhir-server/src/main/java/com/ibm/fhir/server/util/RestAuditLogger.java

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

Co-authored-by: Lee Surprenant <lmsurpre@us.ibm.com>

* doc: compilation errors are now fixed

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: compilation errors are now fixed

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1796

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1797

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests for cp and #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: #1808

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests for plain and base64 encoded environment variables

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix per comments in code review and issue

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Prevent unauthorized reads before they happen

This prevents us from leaking information about what patient resources
exist / don't exist on the system, which was deemed as useful in case an
implementer uses sensitive data for the Resource.id of the Patient
resources (which still isn't advised).

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Prevent unauthorized vread and history operations against Patient too

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* doc: adding code of conduct md file to root of repository

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update to clarify the experimental use of the ibm-fhir-schematool

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update to clarify the experimental use of the ibm-fhir-schematool

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: adding code of conduct md file to root of repository

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* add communication method

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Audit Refactoring #1542

- Refactor to separate Configuration, Mapping and AuditService
- Configuration to use EventStreams Binding by default
- Add a MapperFactory to split between cadf and auditevent types
	- AuditEventMapper - Wraps the AuditLogEntry into AuditEvent format
	- CADFMapper - Wraps the AuditLogEntry into CADF format
- Audit Service is now KafkaService, NoOpService separating the
Streaming framework from the mapping actions.
- Removed duplicate code for Event/EventStrams processing
- Add Test Coverage for Uncovered Classes

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Clean up spare printStackTrace

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update the documentation for fhir-audit

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* updates per team code review

- Change NoOp to Nop Service
- Remove references to WHC/Disabled
- Changed and clarified package names
- Changed references to specific default places to generic/unknown
places (e.g. dallas to unknown)
- added examples for audit from config and audit from environment

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* issue #1818 reindex resource selection update slows down as reindex progresses

Signed-off-by: Robin Arnold <robin.arnold23@ibm.com>

* updates per team code review

- changed package names to remove logging.api and .model (reconciling it
to a flatter structure)

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update docs

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* change formatting slightly on MapperFactory

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: it tests were not running for drug formulary and c4bb

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix incorrect variable in minor startup log message

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Convert Strings to Constants for Kafka Key-Value in Properties objects

- Per Code Review with Robin Arnold

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Code Review for FHIR Audit

- CadfEvent doesn't write out target
- Addresses Written Twice in CadfResource

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Added Test for FHIR Audit so it doesn't have multiple address blocks

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update docs

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Removed auditLogService <extension url="http://ibm.com/fhir/extension/auditLogProperties">

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: referenced license was incorrect

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

Co-authored-by: Paul Bastide <pbastide@us.ibm.com>
Co-authored-by: Mike Schroeder <mschroed@us.ibm.com>
Co-authored-by: Robin Arnold <robin.arnold23@ibm.com>
Co-authored-by: Lee Surprenant <lmsurpre@us.ibm.com>
Co-authored-by: Michael W Schroeder <66479070+michaelwschroeder@users.noreply.github.com>
JohnTimm added a commit that referenced this issue Dec 22, 2020
* Enable OpenLiberty override the fhiropenapi functionality #1760

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Issue #1780 - add compartment search/search parameter config section

Signed-off-by: Mike Schroeder <mschroed@us.ibm.com>

* issue #1789 refresh-tenants does not handle Db2 multi-tenant/multi-schema scenarios

Signed-off-by: Robin Arnold <robin.arnold23@ibm.com>

* Invalid SQL object name `--pool-size` exception when running Docker
`fhir-persistence-schema` on PostgreSQL #1797

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Misleading error messages when using command line parameters and not
`persistence.json` for Docker `fhir-persistence-schema` #1796

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Schema defined for `fhir` in `persistence.json` not used correctly when
running Docker `fhir-persistence-schema`
#1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update must gather to include open shift details

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* use the fhiruser password from helm (set by overrides from KeyProtect)

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Fix the definition for List-identifier search

A workaround for https://jira.hl7.org/browse/FHIR-29937

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Fix up the Must Gather

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* IBM FHIR Server audit does not log bundles correctly. #1803

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update documentation for the mustgather

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: per code review changed the compare, and added an additional ignore
for the metadata endpoints

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Update fhir-server/src/main/java/com/ibm/fhir/server/util/RestAuditLogger.java

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

Co-authored-by: Lee Surprenant <lmsurpre@us.ibm.com>

* doc: compilation errors are now fixed

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: compilation errors are now fixed

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1795

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1796

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests case and fixes for #1797

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests for cp and #1802

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: #1808

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Add tests for plain and base64 encoded environment variables

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix per comments in code review and issue

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Prevent unauthorized reads before they happen

This prevents us from leaking information about what patient resources
exist / don't exist on the system, which was deemed as useful in case an
implementer uses sensitive data for the Resource.id of the Patient
resources (which still isn't advised).

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Prevent unauthorized vread and history operations against Patient too

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* doc: adding code of conduct md file to root of repository

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update to clarify the experimental use of the ibm-fhir-schematool

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: update to clarify the experimental use of the ibm-fhir-schematool

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* doc: adding code of conduct md file to root of repository

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* add communication method

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Audit Refactoring #1542

- Refactor to separate Configuration, Mapping and AuditService
- Configuration to use EventStreams Binding by default
- Add a MapperFactory to split between cadf and auditevent types
	- AuditEventMapper - Wraps the AuditLogEntry into AuditEvent format
	- CADFMapper - Wraps the AuditLogEntry into CADF format
- Audit Service is now KafkaService, NoOpService separating the
Streaming framework from the mapping actions.
- Removed duplicate code for Event/EventStrams processing
- Add Test Coverage for Uncovered Classes

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Clean up spare printStackTrace

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update the documentation for fhir-audit

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* updates per team code review

- Change NoOp to Nop Service
- Remove references to WHC/Disabled
- Changed and clarified package names
- Changed references to specific default places to generic/unknown
places (e.g. dallas to unknown)
- added examples for audit from config and audit from environment

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* issue #1818 reindex resource selection update slows down as reindex progresses

Signed-off-by: Robin Arnold <robin.arnold23@ibm.com>

* updates per team code review

- changed package names to remove logging.api and .model (reconciling it
to a flatter structure)

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update docs

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* change formatting slightly on MapperFactory

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: it tests were not running for drug formulary and c4bb

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix incorrect variable in minor startup log message

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>

* Convert Strings to Constants for Kafka Key-Value in Properties objects

- Per Code Review with Robin Arnold

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Update to 4.6.0-SNAPSHOT

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Code Review for FHIR Audit

- CadfEvent doesn't write out target
- Addresses Written Twice in CadfResource

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Added Test for FHIR Audit so it doesn't have multiple address blocks

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update docs

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Removed auditLogService <extension url="http://ibm.com/fhir/extension/auditLogProperties">

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* fix: referenced license was incorrect

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* Package name consistency issue after Code Review of FHIR-Audit Config
Examples

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* issue #1831 - fix search parameter filtering issue

Signed-off-by: Mike Schroeder <mschroed@us.ibm.com>

* issue #1739 - Update _include and _revinclude parameter checking

Signed-off-by: Troy Biesterfeld <tbieste@us.ibm.com>

* Update .index.json

Warning about invalid entry when discovering HREX profile. 
An example snuck into the .index.json. 

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

* update changelog.md

Signed-off-by: Paul Bastide <pbastide@us.ibm.com>

Co-authored-by: Paul Bastide <pbastide@us.ibm.com>
Co-authored-by: Mike Schroeder <mschroed@us.ibm.com>
Co-authored-by: Robin Arnold <robin.arnold23@ibm.com>
Co-authored-by: Lee Surprenant <lmsurpre@us.ibm.com>
Co-authored-by: Michael W Schroeder <66479070+michaelwschroeder@users.noreply.github.com>
Co-authored-by: Troy Biesterfeld <tbieste@us.ibm.com>
@d0roppe
Copy link
Collaborator

d0roppe commented Jan 7, 2021

Verified that specifying a schema name other than fhirdata works fine now. Using the same information as in the recreate steps of this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cloud portability
Projects
None yet
4 participants