Skip to content

Commit 47a31e0

Browse files
auto commit
1 parent 6ab22b9 commit 47a31e0

File tree

7 files changed

+50
-11
lines changed

7 files changed

+50
-11
lines changed

Examples/runtimes/java/DynamoDbEncryption/src/main/java/software/amazon/cryptography/examples/BasicPutGetExample.java

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,9 +203,9 @@ public static void PutItemGetItem(
203203
public static void main(final String[] args) {
204204
if (args.length < 6) {
205205
throw new IllegalArgumentException(
206-
"To run this example, include the kmsKeyId as args[0], ddbTableName as args[1],"
207-
+ " partitionKeyName as args[2], sortKeyName as args[3], partitionKeyValue as args[4]"
208-
+ " sortKeyValue as args[5]"
206+
"To run this example, include the kmsKeyId as args[0], ddbTableName as args[1]," +
207+
" partitionKeyName as args[2], sortKeyName as args[3], partitionKeyValue as args[4]" +
208+
" sortKeyValue as args[5]"
209209
);
210210
}
211211
final String kmsKeyId = args[0];
@@ -214,6 +214,13 @@ public static void main(final String[] args) {
214214
final String sortKeyName = args[3];
215215
final String partitionKeyValue = args[4];
216216
final String sortKeyValue = args[5];
217-
PutItemGetItem(kmsKeyId, ddbTableName, partitionKeyName, sortKeyName, partitionKeyValue, sortKeyValue);
217+
PutItemGetItem(
218+
kmsKeyId,
219+
ddbTableName,
220+
partitionKeyName,
221+
sortKeyName,
222+
partitionKeyValue,
223+
sortKeyValue
224+
);
218225
}
219226
}

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/TestUtils.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
package software.amazon.cryptography.examples.migration;
22

33
import java.util.HashMap;
4+
import java.util.UUID;
45
import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
56
import software.amazon.awssdk.services.dynamodb.model.AttributeValue;
67
import software.amazon.awssdk.services.dynamodb.model.DeleteItemRequest;
7-
import java.util.UUID;
88

99
public class TestUtils {
1010

@@ -18,7 +18,7 @@ public class TestUtils {
1818

1919
public static final String PARTITION_KEY =
2020
"PlaintextMigrationExample" + UUID.randomUUID();
21-
21+
2222
/**
2323
* Deletes an item from a DynamoDB table.
2424
*

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/awsdbe/TestMigrationExampleStep1.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,13 @@ public void TestMigrationStep1() {
6666
);
6767
List<String> sortkeys = Arrays.asList("0", "1", "2", "3");
6868
for (String sortkey : sortkeys) {
69-
TestUtils.cleanUpDDBItem(TestUtils.TEST_DDB_TABLE_NAME, "partition_key", "sort_key", TestUtils.PARTITION_KEY, sortkey);
69+
TestUtils.cleanUpDDBItem(
70+
TestUtils.TEST_DDB_TABLE_NAME,
71+
"partition_key",
72+
"sort_key",
73+
TestUtils.PARTITION_KEY,
74+
sortkey
75+
);
7076
}
7177
}
7278
}

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/awsdbe/TestMigrationExampleStep2.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,13 @@ public void TestMigrationStep2() {
6666
);
6767
List<String> sortkeys = Arrays.asList("0", "1", "2", "3");
6868
for (String sortkey : sortkeys) {
69-
TestUtils.cleanUpDDBItem(TestUtils.TEST_DDB_TABLE_NAME, "partition_key", "sort_key", TestUtils.PARTITION_KEY, sortkey);
69+
TestUtils.cleanUpDDBItem(
70+
TestUtils.TEST_DDB_TABLE_NAME,
71+
"partition_key",
72+
"sort_key",
73+
TestUtils.PARTITION_KEY,
74+
sortkey
75+
);
7076
}
7177
}
7278
}

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/awsdbe/TestMigrationExampleStep3.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package software.amazon.cryptography.examples.migration.awsdbe;
22

33
import static org.testng.Assert.assertThrows;
4+
45
import java.util.Arrays;
56
import java.util.List;
67
import org.testng.annotations.Test;
@@ -78,7 +79,13 @@ public void TestMigrationStep0() {
7879
);
7980
List<String> sortkeys = Arrays.asList("0", "1", "2", "3");
8081
for (String sortkey : sortkeys) {
81-
TestUtils.cleanUpDDBItem(TestUtils.TEST_DDB_TABLE_NAME, "partition_key", "sort_key", TestUtils.PARTITION_KEY, sortkey);
82+
TestUtils.cleanUpDDBItem(
83+
TestUtils.TEST_DDB_TABLE_NAME,
84+
"partition_key",
85+
"sort_key",
86+
TestUtils.PARTITION_KEY,
87+
sortkey
88+
);
8289
}
8390
}
8491
}

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/awsdbe/encrypttable/TestEncryptExistingTable.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,13 @@ public void TestEncryptExistingTable() {
209209

210210
List<String> sortkeys = Arrays.asList("0", "1", "2");
211211
for (String sortkey : sortkeys) {
212-
TestUtils.cleanUpDDBItem(TestUtils.TEST_DDB_TABLE_NAME, "partition_key", "sort_key", TestUtils.PARTITION_KEY, sortkey);
212+
TestUtils.cleanUpDDBItem(
213+
TestUtils.TEST_DDB_TABLE_NAME,
214+
"partition_key",
215+
"sort_key",
216+
TestUtils.PARTITION_KEY,
217+
sortkey
218+
);
213219
}
214220
}
215221
}

Examples/runtimes/java/Migration/PlaintextToAWSDBE/src/test/java/software/amazon/cryptography/examples/migration/plaintext/TestMigrationExampleStep0.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package software.amazon.cryptography.examples.migration.plaintext;
22

33
import static org.testng.Assert.assertThrows;
4+
45
import java.util.Arrays;
56
import java.util.List;
67
import org.testng.annotations.Test;
@@ -74,7 +75,13 @@ public void TestMigrationStep0() {
7475
);
7576
List<String> sortkeys = Arrays.asList("0", "1", "2", "3");
7677
for (String sortkey : sortkeys) {
77-
TestUtils.cleanUpDDBItem(TestUtils.TEST_DDB_TABLE_NAME, "partition_key", "sort_key", TestUtils.PARTITION_KEY, sortkey);
78+
TestUtils.cleanUpDDBItem(
79+
TestUtils.TEST_DDB_TABLE_NAME,
80+
"partition_key",
81+
"sort_key",
82+
TestUtils.PARTITION_KEY,
83+
sortkey
84+
);
7885
}
7986
}
8087
}

0 commit comments

Comments
 (0)