Skip to content

Commit df2f65d

Browse files
sliedigSDE Workshop Usereldritchideen
authored
Unicorn approvals (#46)
* feat: add command to list the parameters in parameters store * refactor: renamed UnicornPropertiesNamespace to UnicornApprovalsNamespace in shared namespace definition * refactor: updated resolve:ssm references for UnicornPropertiesNamespace to UnicornApprovalsNamespace across multiple templates * refactor: change event bus references from UnicornPropertiesEventBus to UnicornApprovalsEventBus across multiple files * chore: upgrade actions/upload-artifact from v3 to v4 in GitHub workflow * feat: refactored unicorn properties to approvals again. Renamed modules to align with oother runtimes. * refactor: updated POM file to rename groupId and artifactId from PropertyService to ApprovalsService for consistency with recent changes * chore: update .gitignore to include new target directories for ApprovalService, ContractsService, SearchService, and Common * refactor: simplify setUp method in CreateContractTests by removing unnecessary exception declaration * refactor: simplify setUp method in ContractStatusTests by removing unnecessary exception declaration * refactor: update POM files to rename artifactId and module names for consistency, and upgrade compiler version to 17 * chore: update .gitignore to reflect the new directory structure for ApprovalsService * feat: refactored unicorn web into separate modules - ApprovalService and SearchService - to align with implementations in other runtimes. * chore: update Approvals readme * chore: updated contracts readme * chore: update web readme * chore: updated main readme * chore: update GitHub Actions workflows to use latest versions of actions and increase build timeout * chore: downgrade Maven compiler version to 17 in Common module * chore: reorder sections in README and update image placement * chore: update README badge link to reflect new GitHub Actions workflow * chore: fix formatting in README by adjusting header and image placement * refactor: change package name from search.requestapproval to approval.requestapproval in RequestApprovalFunction.java * chore: update architecture diagram * refactor: update event source and rule names to use 'unicorn.approvals' * refactor: change package names from 'unicorn_properties' to 'unicorn_approvals' in related classes * refactor: rename ApprovalService to PublicationManagerService and removed classes in the ApprovalsService module as this does not need to be tracked. * chore: minor update to readme file * fix: update namespace for event schema * fix: updated references to properties service to approvals service. Fixed SAM templates to refer to new Java services. Updated .gitignore. Updated test events. * chore: updated approvals readme * chore: updated readme and spelling mistakes * fix: syncing templates * Updated Java dependencies and Code (#47) * Updated unicorn approvals dependencies and updated code. * Updated Unicorn Contracts. * Updated unicorn web. --------- Co-authored-by: SDE Workshop User <ec2-user@sde-workshop.local> Co-authored-by: Steven Cook <awscook@amazon.com>
1 parent 64ebff3 commit df2f65d

File tree

116 files changed

+2415
-1833
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+2415
-1833
lines changed

.github/workflows/auto_assign.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ jobs:
77
add-reviews:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: kentaro-m/auto-assign-action@v1.2.5
10+
- uses: kentaro-m/auto-assign-action@v2.0.0

.github/workflows/build.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ on:
55
branches: [develop, main]
66
paths:
77
- 'unicorn_contracts/**'
8-
- 'unicorn_properties/**'
8+
- 'unicorn_approvals/**'
99
- 'unicorn_web/**'
1010
pull_request:
1111
branches: [develop, main]
1212
paths:
1313
- 'unicorn_contracts/**'
14-
- 'unicorn_properties/**'
14+
- 'unicorn_approvals/**'
1515
- 'unicorn_web/**'
1616

1717
defaults:
@@ -21,22 +21,22 @@ defaults:
2121
jobs:
2222
build:
2323
runs-on: ubuntu-latest
24-
timeout-minutes: 5
24+
timeout-minutes: 10
2525
strategy:
2626
max-parallel: 4
2727
matrix:
28-
# test against latest update of each major Java version, as well as specific updates of LTS versions:
29-
java: [17]
28+
# test against latest LTS Java versions
29+
java: [17, 21]
3030
name: Java ${{ matrix.java }}
3131
env:
3232
JAVA: ${{ matrix.java }}
3333
AWS_REGION: us-west-2
3434
steps:
35-
- uses: actions/checkout@v3
36-
- name: Setup java
35+
- uses: actions/checkout@v4
36+
- name: Setup Java
3737
uses: actions/setup-java@v4
3838
with:
39-
distribution: 'zulu'
39+
distribution: 'temurin'
4040
java-version: ${{ matrix.java }}
4141
cache: maven
4242
cache-dependency-path: '**/pom.xml'

.github/workflows/codeql-analysis.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,24 +26,24 @@ jobs:
2626

2727
steps:
2828
- name: Checkout repository
29-
uses: actions/checkout@v3
29+
uses: actions/checkout@v4
3030

3131
- name: Setup Java JDK
32-
uses: actions/setup-java@v3
32+
uses: actions/setup-java@v4
3333
with:
3434
distribution: 'temurin'
35-
java-version: 17
35+
java-version: 21
3636

3737
# Initializes the CodeQL tools for scanning.
3838
- name: Initialize CodeQL
39-
uses: github/codeql-action/init@2ca79b6fa8d3ec278944088b4aa5f46912db5d63 #v2
39+
uses: github/codeql-action/init@v3
4040
with:
4141
languages: ${{ matrix.language }}
4242

4343
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
4444
# If this step fails, then you should remove it and run the build manually (see below)
4545
- name: Autobuild
46-
uses: github/codeql-action/autobuild@2ca79b6fa8d3ec278944088b4aa5f46912db5d63 #v2
46+
uses: github/codeql-action/autobuild@v3
4747

4848
# ℹ️ Command-line programs to run using the OS shell.
4949
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
@@ -56,4 +56,4 @@ jobs:
5656
# ./location_of_script_within_repo/buildscript.sh
5757

5858
- name: Perform CodeQL Analysis
59-
uses: github/codeql-action/analyze@2ca79b6fa8d3ec278944088b4aa5f46912db5d63 #v2
59+
uses: github/codeql-action/analyze@v3

.github/workflows/label_pr_on_title.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- name: Checkout repository
25-
uses: actions/checkout@v3
25+
uses: actions/checkout@v4
2626
- name: "Label PR based on title"
27-
uses: actions/github-script@v6
27+
uses: actions/github-script@v7
2828
env:
2929
PR_NUMBER: ${{ needs.get_pr_details.outputs.prNumber }}
3030
PR_TITLE: ${{ needs.get_pr_details.outputs.prTitle }}

.github/workflows/on_label_added.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ jobs:
2323
issues: write
2424
pull-requests: write
2525
steps:
26-
- uses: actions/checkout@v3
26+
- uses: actions/checkout@v4
2727
# Maintenance: Persist state per PR as an artifact to avoid spam on label add
2828
- name: "Suggest split large Pull Request"
29-
uses: actions/github-script@v6
29+
uses: actions/github-script@v7
3030
env:
3131
PR_NUMBER: ${{ needs.get_pr_details.outputs.prNumber }}
3232
PR_ACTION: ${{ needs.get_pr_details.outputs.prAction }}

.github/workflows/on_merged_pr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ jobs:
2020
runs-on: ubuntu-latest
2121
if: needs.get_pr_details.outputs.prIsMerged == 'true'
2222
steps:
23-
- uses: actions/checkout@v3
23+
- uses: actions/checkout@v4
2424
- name: "Label PR related issue for release"
25-
uses: actions/github-script@v6
25+
uses: actions/github-script@v7
2626
env:
2727
PR_NUMBER: ${{ needs.get_pr_details.outputs.prNumber }}
2828
PR_BODY: ${{ needs.get_pr_details.outputs.prBody }}

.github/workflows/on_opened_pr.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ jobs:
1919
needs: get_pr_details
2020
runs-on: ubuntu-latest
2121
steps:
22-
- uses: actions/checkout@v3
22+
- uses: actions/checkout@v4
2323
- name: "Ensure related issue is present"
24-
uses: actions/github-script@v6
24+
uses: actions/github-script@v7
2525
env:
2626
PR_BODY: ${{ needs.get_pr_details.outputs.prBody }}
2727
PR_NUMBER: ${{ needs.get_pr_details.outputs.prNumber }}
@@ -36,9 +36,9 @@ jobs:
3636
needs: get_pr_details
3737
runs-on: ubuntu-latest
3838
steps:
39-
- uses: actions/checkout@v3
39+
- uses: actions/checkout@v4
4040
- name: "Ensure acknowledgement section is present"
41-
uses: actions/github-script@v6
41+
uses: actions/github-script@v7
4242
env:
4343
PR_BODY: ${{ needs.get_pr_details.outputs.prBody }}
4444
PR_NUMBER: ${{ needs.get_pr_details.outputs.prNumber }}

.github/workflows/record_pr.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ jobs:
99
runs-on: ubuntu-latest
1010

1111
steps:
12-
- uses: actions/checkout@v3
12+
- uses: actions/checkout@v4
1313
- name: "Extract PR details"
14-
uses: actions/github-script@v6
14+
uses: actions/github-script@v7
1515
with:
1616
script: |
1717
const script = require('.github/scripts/save_pr_details.js')
1818
await script({github, context, core})
19-
- uses: actions/upload-artifact@v3
19+
- uses: actions/upload-artifact@v4
2020
with:
2121
name: pr
2222
path: pr.txt

.github/workflows/reusable_export_pr_details.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ jobs:
5353
prIsMerged: ${{ steps.prIsMerged.outputs.prIsMerged }}
5454
steps:
5555
- name: Checkout repository # in case caller workflow doesn't checkout thus failing with file not found
56-
uses: actions/checkout@v3
56+
uses: actions/checkout@v4
5757
- name: "Download previously saved PR"
58-
uses: actions/github-script@v6
58+
uses: actions/github-script@v7
5959
env:
6060
WORKFLOW_ID: ${{ inputs.record_pr_workflow_id }}
6161
# For security, we only download artifacts tied to the successful PR recording workflow

.gitignore

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1-
unicorn_properties/PropertyFunctions/target/*
2-
unicorn_contracts/ContractsFunction/target/**
3-
unicorn_web/PropertyFunctions/target/**
1+
unicorn_approvals/ApprovalsService/target/**
2+
unicorn_contracts/ContractsService/target/**
3+
unicorn_web/ApprovalService/target/**
4+
unicorn_web/SearchService/target/**
5+
unicorn_web/PublicationManagerService/target/**
6+
unicorn_web/Common/target/**
47
**/.aws-sam/
58
.DS_Store**
69
.vscode/settings.json
710
buildall.sh
811
deleteall.sh
912
/.idea/**
1013
/cloudapp.iml
11-
/unicorn_properties/PropertyFunctions/PropertyService.iml
14+
/unicorn_approvals/PropertyFunctions/PropertyService.iml
1215
/unicorn_web/PropertyFunctions/PropertyWeb.iml
1316
/unicorn_contracts/ContractsFunction/ContractsModule.iml
14-
**/cdk.out/
17+
**/cdk.out/
18+
**/dependency-reduced-pom.xml

0 commit comments

Comments
 (0)