Skip to content

Commit

Permalink
feat(ihe): develop to branch
Browse files Browse the repository at this point in the history
Refs: #1667
Signed-off-by: Jonah Kaye <[email protected]>
  • Loading branch information
jonahkaye committed Jun 21, 2024
2 parents dc7076f + 5dddf11 commit 7024462
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ import {
dayjs.extend(duration);

const { log } = out("Saml Client");
const httpTimeout = dayjs.duration({ seconds: 120 });
const httpTimeoutPatientDiscovery = dayjs.duration({ seconds: 60 });
const httpTimeoutDocumentQuery = dayjs.duration({ seconds: 120 });
const httpTimeoutDocumentRetrieve = dayjs.duration({ seconds: 120 });
const initialDelay = dayjs.duration({ seconds: 3 });
const maxPayloadSize = Infinity;
let rejectUnauthorized = true;
Expand Down Expand Up @@ -91,7 +93,9 @@ export async function sendSignedXml({
const response = await executeWithNetworkRetries(
async () => {
return axios.post(url, signedXml, {
timeout: httpTimeout.asMilliseconds(),
timeout: isDq
? httpTimeoutDocumentQuery.asMilliseconds()
: httpTimeoutPatientDiscovery.asMilliseconds(),
headers: {
"Content-Type": "application/soap+xml;charset=UTF-8",
Accept: "application/soap+xml",
Expand Down Expand Up @@ -141,7 +145,7 @@ export async function sendSignedXmlMtom({
const response = await executeWithNetworkRetries(
async () => {
return axios.post(url, payload, {
timeout: httpTimeout.asMilliseconds(),
timeout: httpTimeoutDocumentRetrieve.asMilliseconds(),
headers: {
"Accept-Encoding": "gzip, deflate",
"Content-Type": contentType,
Expand Down
4 changes: 2 additions & 2 deletions packages/infra/lib/ihe-gateway-v2-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ export class IHEGatewayV2LambdasNestedStack extends NestedStack {
},
layers: [lambdaLayers.shared],
memory: 4096,
timeout: Duration.minutes(5),
timeout: Duration.minutes(10),
vpc,
});

Expand Down Expand Up @@ -198,7 +198,7 @@ export class IHEGatewayV2LambdasNestedStack extends NestedStack {
},
layers: [lambdaLayers.shared],
memory: 1024,
timeout: Duration.minutes(5),
timeout: Duration.minutes(10),
vpc,
});

Expand Down

0 comments on commit 7024462

Please sign in to comment.