FHIR icon indicating copy to clipboard operation
FHIR copied to clipboard

[fhir-bucket] Repeated benign error when run with --scan-local-dir

Open lmsurpre opened this issue 3 years ago • 1 comments

Describe the bug I ran the fhir-bucket cli with arguments like this:

--fhir-properties fhir.properties
--immediate-local
--scan-local-dir /Users/lmsurpre//git/synthea/output/fhir

It worked just fine, but I see this error message repeated in the output multiple times:

Mar 09, 2022 7:39:08 AM com.ibm.fhir.bucket.scanner.LocalFileScanner mainLoop SEVERE: Error during COS scan: null

Environment main

To Reproduce Steps to reproduce the behavior:

  1. run the tool with these arguments

Expected behavior if the fhir.properties are right and the server is up, it works. otherwise, it fails to upload, but it shouldn't produce misleading errors about a COS scan.

Additional context You can pass --no-scan to avoid the issue. But I think we should set that automatically if --scan-local-dir was passed (unless we want to support doing them both from a single run in which case we'd need to rename it I think)

lmsurpre avatar Mar 09 '22 12:03 lmsurpre

somewhat related: i think we should have this simple flavor of the command documented somewhere near the top.

currently we walk through a lot of detail about how it works and all the options for using it from COS (since that was the main focus of the project). then we get to "oh and it works for local too" but we give this command:

java \
  -Djava.util.logging.config.file=logging.properties \
  -jar "${JAR}" \
  --db-type postgresql \
  --db-properties db.properties \
  --fhir-properties fhir.properties \
  --tenant-name your-tenant-name \
  --file-type JSON \
  --max-concurrent-fhir-requests 0 \
  --max-concurrent-json-files 0 \
  --max-concurrent-ndjson-files 0 \
  --connection-pool-size 10 \
  --immediate-local \
  --scan-local-dir /path/to/synthea/data

The options are great, but a little overwhelming for the "I just generated a few sample patients from synthea and now I want to upload it to a server" use case.

lmsurpre avatar Mar 09 '22 12:03 lmsurpre