From 753949081cfdeaf862edf69220154cd267b73e91 Mon Sep 17 00:00:00 2001 From: Paul Gilzow Date: Fri, 13 Dec 2024 15:51:10 -0600 Subject: [PATCH 1/4] adds retry_sleep input to the redirection verification action, refactors redirection checks to add a number of retries with a pause delay between each retry attempt (#4305) --- .../redirection-verification/action.yaml | 6 +- .../actions/redirection-verification/index.js | 56 +++++++++++++------ 2 files changed, 45 insertions(+), 17 deletions(-) diff --git a/.github/actions/redirection-verification/action.yaml b/.github/actions/redirection-verification/action.yaml index a27e6cdf78..fddef46883 100644 --- a/.github/actions/redirection-verification/action.yaml +++ b/.github/actions/redirection-verification/action.yaml @@ -5,9 +5,13 @@ inputs: description: 'Pull Request Environment URL' required: true number_retries: - description: 'The number of attempts we should make to contact the target environment URL. 1 second delay between attempt.' + description: 'The number of attempts we should make to contact the target environment URL.' required: false default: '100' + retry_sleep: + description: 'The length of time (in ms) to pause between each attempt at trying the redirect.' + required: false + default: '1000' #### #outputs: diff --git a/.github/actions/redirection-verification/index.js b/.github/actions/redirection-verification/index.js index cc806da80b..db8cd150ac 100644 --- a/.github/actions/redirection-verification/index.js +++ b/.github/actions/redirection-verification/index.js @@ -37,6 +37,7 @@ function linkify(path,url) { axios.defaults.baseURL = core.getInput('environment-url') //axios.defaults.baseURL = 'https://httpstat.us/random/200,500-504,500-504,500-504' const retries = Number(core.getInput('number_retries')) +const retrySleep = Number(core.getInput('retry_sleep')) //const retries = Number('100') function sleep(ms) { return new Promise((resolve) => { @@ -44,28 +45,50 @@ function sleep(ms) { }); } -const verifyTargetResponse = async(count = 0) => { +const retryTargetResponse = async (url='/',count=0) => { try { - const axiosResponse = await axios.get('/'); - core.notice('Target URL finally responded with a 200. Proceeding.') + const axiosResponse = await axios.head(url); return axiosResponse; } catch (error) { - if (error || error.status != 200) { - core.info(`At attempt ${count}, target url responded with status ${error.status}, retrying...`) + if(error || error.status != 200) { + core.debug(`At attempt ${count}, target url ${url} responded with status ${error.status}, retrying...`) if (count++ < retries) { - await sleep(1000); - return verifyTargetResponse(count); + await sleep(retrySleep) + return retryTargetResponse(url,count) } else { - core.setFailed(`Max number of retries (${retries}) reached. Aborting.`) - }; + core.warning(`Max number of retries ${retries} for end point ${url} reached. Aborting.`) + throw new Error(error) + } } else { - core.setFailed(`Action failed with error ${error}`) - }; - }; -}; + core.warning(`Action failed with error ${error}`) + throw new Error(error) + } + } +} + +// const verifyTargetResponse = async(count = 0) => { +// try { +// const axiosResponse = await axios.get('/'); +// core.notice('Target URL finally responded with a 200. Proceeding.') +// return axiosResponse; +// } catch (error) { +// if (error || error.status != 200) { +// core.info(`At attempt ${count}, target url responded with status ${error.status}, retrying...`) +// if (count++ < retries) { +// await sleep(1000); +// return verifyTargetResponse(count); +// } else { +// core.setFailed(`Max number of retries (${retries}) reached. Aborting.`) +// }; +// } else { +// core.setFailed(`Action failed with error ${error}`) +// }; +// }; +// }; const verify = async () => { - let targetReady = await verifyTargetResponse(); + // let targetReady = await verifyTargetResponse(); + let targetReady = await retryTargetResponse('/'); core.info('Target URL ready. Beginning verification.') try { /** @@ -90,12 +113,13 @@ const verify = async () => { core.debug(`I'm going to test ${path} to see if it goes to ${anchors[path].to}`) try { - const response = await axios.head(path); + const response = await retryTargetResponse(path); + //const response = await axios.head(path); core.debug(`Response for our check of ${path} is ${response.status}`) return response } catch (reqerr) { // core.debug(`issue encountered with path ${path}!!! Returned status is ${reqerr.status}. More info: `) - core.info(`issue encountered with path ${path}!!! Returned status is ${reqerr.status}. More info: `) + core.debug(`issue encountered with path ${path}!!! Returned status is ${reqerr.status}. More info: `) core.debug(JSON.stringify(reqerr)) if(axios.isAxiosError(reqerr)) { // core.debug(reqerr.toJSON()) From 56bcace49d128adb738fb8b974cf8ea1a0e4b794 Mon Sep 17 00:00:00 2001 From: Chad Carlson Date: Mon, 16 Dec 2024 08:50:56 -0500 Subject: [PATCH 2/4] Symfony Partner tag --- sites/platform/src/guides/symfony/_index.md | 1 + 1 file changed, 1 insertion(+) diff --git a/sites/platform/src/guides/symfony/_index.md b/sites/platform/src/guides/symfony/_index.md index 6a846d7633..56cbb9bbe6 100644 --- a/sites/platform/src/guides/symfony/_index.md +++ b/sites/platform/src/guides/symfony/_index.md @@ -1,6 +1,7 @@ --- title: "Symfony" weight: -150 +partner: true description: | Everything you need to get started with [Symfony](https://www.symfony.com/), a [PHP](../../development/templates.md#php) framework for web development, on {{% vendor/name %}}. --- From 7023185bd3818844b3ad09a7ef7894f67246e2ff Mon Sep 17 00:00:00 2001 From: Chad Carlson Date: Mon, 16 Dec 2024 08:52:00 -0500 Subject: [PATCH 3/4] Replicate for Upsun --- sites/upsun/src/get-started/stacks/symfony/_index.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sites/upsun/src/get-started/stacks/symfony/_index.md b/sites/upsun/src/get-started/stacks/symfony/_index.md index 676274e6c4..61941601f4 100644 --- a/sites/upsun/src/get-started/stacks/symfony/_index.md +++ b/sites/upsun/src/get-started/stacks/symfony/_index.md @@ -2,6 +2,7 @@ title: Deploy Symfony on {{% vendor/name %}} sidebarTitle: Symfony layout: single +partner: true weight: -60 description: | Complete the last required steps to successfully deploy Symfony on {{% vendor/name %}}. @@ -43,4 +44,4 @@ They provide all of the core concepts and common commands you need to know befor - [Refactoring monolith to multi-app](https://youtu.be/5hApjWiTO1M?feature=shared) - [{{% vendor/name %}}: From zero to scaling hero](https://youtu.be/FEFBUomV5aY?feature=shared) -{{< guide-buttons next="Get started" nextLink="/get-started/stacks/symfony/get-started.md" type="*" >}} \ No newline at end of file +{{< guide-buttons next="Get started" nextLink="/get-started/stacks/symfony/get-started.md" type="*" >}} From d44a9dd63edbfb651613071664c420f80b075e38 Mon Sep 17 00:00:00 2001 From: Kemi Elizabeth <97071326+Kemi-Elizabeth@users.noreply.github.com> Date: Mon, 16 Dec 2024 15:26:13 +0000 Subject: [PATCH 4/4] feat: added new version to varnish (#4308) Updated registry.json file with new version of Varnish Co-authored-by: Chad Carlson --- shared/data/registry.json | 1 + 1 file changed, 1 insertion(+) diff --git a/shared/data/registry.json b/shared/data/registry.json index 2b344d49aa..d3816ff508 100644 --- a/shared/data/registry.json +++ b/shared/data/registry.json @@ -1262,6 +1262,7 @@ "7.1" ], "supported": [ + "7.6", "7.3", "7.2", "6.0"