2727 strategy :
2828 matrix :
2929 library : [TestVectors]
30- java-version : [8, 11, 17, 19 ]
30+ java-version : [8, 11, 16, 17 ]
3131 os : [
3232 # Run on ubuntu image that comes pre-configured with docker
3333 ubuntu-22.04,
@@ -37,49 +37,19 @@ jobs:
3737 id-token : write
3838 contents : read
3939 steps :
40+ - name : Setup DynamoDB Local
41+ 42+ with :
43+ port : 8000
44+ cors : " *"
45+
4046 - name : Configure AWS Credentials
4147 uses : aws-actions/configure-aws-credentials@v4
4248 with :
4349 aws-region : us-west-2
4450 role-to-assume : arn:aws:iam::370957321024:role/GitHub-CI-DDBEC-Dafny-Role-us-west-2
4551 role-session-name : DDBEC-Dafny-Java-Tests
4652
47- - name : Install Java
48- uses : actions/setup-java@v5
49- with :
50- distribution : " corretto"
51- java-version : " 11" # DynamoDB Local requires Java
52-
53- - name : Download DynamoDB Local
54- run : |
55- wget https://dynamodb-local.s3.amazonaws.com/dynamodb_local_latest.tar.gz
56- tar -xf dynamodb_local_latest.tar.gz
57-
58- - name : Start DynamoDB Local
59- run : |
60- java -Djava.library.path=./DynamoDBLocal_lib -jar DynamoDBLocal.jar \
61- -inMemory -sharedDb -port 8000 > dynamodb-local.log 2>&1 &
62- echo $! > dynamodb-local.pid
63-
64- - name : Wait for DynamoDB Local
65- run : |
66- echo "Waiting for DynamoDB Local to start..."
67- for i in {1..30}; do
68- if curl -s -f http://localhost:8000 > /dev/null 2>&1; then
69- echo "DynamoDB Local is ready"
70- break
71- fi
72- echo "Attempt $i: DynamoDB Local not ready yet..."
73- sleep 2
74- done
75- # Verify it's actually working with dummy credentials
76- curl -X POST http://localhost:8000 \
77- -H "Content-Type: application/x-amz-json-1.0" \
78- -H "X-Amz-Target: DynamoDB_20120810.ListTables" \
79- -H "Authorization: AWS4-HMAC-SHA256 Credential=dummy/20230101/us-east-1/dynamodb/aws4_request, SignedHeaders=host;x-amz-date, Signature=dummy" \
80- -H "X-Amz-Date: 20230101T000000Z" \
81- -d '{}' || (cat dynamodb-local.log && exit 1)
82-
8353 - uses : actions/checkout@v3
8454 with :
8555 submodules : recursive
9868 git submodule update --init --recursive
9969 git rev-parse HEAD
10070
101- - name : Setup Java 8
102- uses : actions/setup-java@v5
103- with :
104- distribution : " corretto"
105- java-version : 8
106-
10771 - name : Setup Java ${{ matrix.java-version }}
108- uses : actions/setup-java@v5
72+ uses : actions/setup-java@v4
10973 with :
11074 distribution : " corretto"
11175 java-version : ${{ matrix.java-version }}
0 commit comments