From 9def037492aa50a246aed26c19d782c8679184d8 Mon Sep 17 00:00:00 2001 From: Basilio Bogado <541149+basiliskus@users.noreply.github.com> Date: Tue, 16 Jan 2024 04:07:27 +0800 Subject: [PATCH] Update ReportStream Setup steps (#765) * Updated rs setup step * Updated step 2 of cdc-ti setup * Fixed indentation * Removed env variable in command invocation as it should now be available via the .env file --- .secrets.baseline | 4 ++-- README.md | 20 +++++++++++--------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/.secrets.baseline b/.secrets.baseline index 2e0cbc5af..42dfdd71b 100644 --- a/.secrets.baseline +++ b/.secrets.baseline @@ -138,7 +138,7 @@ "filename": "README.md", "hashed_secret": "e07f44b0222f3680e0a3491edcf61030143e2ae7", "is_verified": false, - "line_number": 269, + "line_number": 271, "is_secret": false } ], @@ -253,5 +253,5 @@ } ] }, - "generated_at": "2024-01-10T19:16:29Z" + "generated_at": "2024-01-11T21:32:16Z" } diff --git a/README.md b/README.md index 05a967535..c5cd0a46c 100644 --- a/README.md +++ b/README.md @@ -222,17 +222,19 @@ For database documentation [go here](/docs/database.md) 1. Checkout `main` branch for `CDCgov/trusted-intermediary` 2. Edit the `app/src/main/java/gov/hhs/cdc/trustedintermediary/etor/EtorDomainRegistration.java` file and replace: ```Java - │ 66 │ if (ApplicationContext.getEnvironment().equalsIgnoreCase("local")) { - │ 67 │ ApplicationContext.register(OrderSender.class, LocalFileOrderSender.getInstance()); - │ 68 │ } else { - │ 69 │ ApplicationContext.register(OrderSender.class, ReportStreamOrderSender.getInstance()); - │ 70 │ } + if (ApplicationContext.getEnvironment().equalsIgnoreCase("local")) { + ApplicationContext.register(RSEndpointClient.class, MockRSEndpointClient.getInstance()); + } else { + ApplicationContext.register(RSEndpointClient.class, ReportStreamEndpointClient.getInstance()); + ApplicationContext.register(AzureClient.class, AzureClient.getInstance()); + } ``` with: ```Java - │ 66 │ ApplicationContext.register(OrderSender.class, ReportStreamOrderSender.getInstance()); + ApplicationContext.register(RSEndpointClient.class, ReportStreamEndpointClient.getInstance()); + ApplicationContext.register(AzureClient.class, AzureClient.getInstance()); ``` -3. Run TI with `REPORT_STREAM_URL_PREFIX=http://localhost:7071 ./gradlew clean app:run` +3. Run TI with `./gradlew clean app:run` #### ReportStream Setup @@ -241,8 +243,8 @@ After enabling this option it is recommended that you delete all docker images a with this option enabled. 1. Checkout `master` branch for `CDCgov/prime-reportstream` -2. Follow [the steps in the ReportStream docs](https://github.com/CDCgov/prime-reportstream/blob/master/prime-router/docs/docs-deprecated/getting-started/getting-started.md#building-the-baseline) to build the baseline -3. CD to `prime-reportstream/prime-router` +2. CD to `prime-reportstream/prime-router` +3. Run the `./cleanslate` script. For more information you can refer to the [ReportStream docs](https://github.com/CDCgov/prime-reportstream/blob/master/prime-router/docs/docs-deprecated/getting-started/getting-started.md#building-the-baseline) 4. Run RS with `docker compose up --build -d` 5. Run `./gradlew resetDB && ./gradlew reloadTable && ./gradlew reloadSettings` 6. Edit `prime-router/settings/staging/0149-etor.yml`