Skip to content

Commit 012ebf9

Browse files
chore(go): add complex example in searchable encryptions (#1955)
1 parent 2e36410 commit 012ebf9

File tree

6 files changed

+2499
-0
lines changed

6 files changed

+2499
-0
lines changed

Examples/runtimes/go/main.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import (
99
"github.com/aws/aws-database-encryption-sdk-dynamodb/examples/keyring"
1010
"github.com/aws/aws-database-encryption-sdk-dynamodb/examples/misc"
1111
"github.com/aws/aws-database-encryption-sdk-dynamodb/examples/searchableencryption"
12+
"github.com/aws/aws-database-encryption-sdk-dynamodb/examples/searchableencryption/complexexample"
1213
"github.com/aws/aws-database-encryption-sdk-dynamodb/examples/utils"
1314
)
1415

@@ -94,4 +95,9 @@ func main() {
9495
branchKey2,
9596
utils.TestKeystoreKmsKeyId(),
9697
utils.TestKeystoreName())
98+
complexexample.ComplexSearchableEncryptionExample(
99+
utils.TestComplexDdbTableName(),
100+
branchKey1,
101+
utils.TestKeystoreKmsKeyId(),
102+
utils.TestKeystoreName())
97103
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# ComplexSearchableEncryptionExample
2+
3+
This example demonstrates complex queries
4+
you can perform using beacons.
5+
The example data used is for demonstrative purposes only,
6+
and might not meet the distribution and correlation uniqueness
7+
recommendations for beacons.
8+
See our documentation for whether beacons are
9+
right for your particular data set:
10+
https://docs.aws.amazon.com/database-encryption-sdk/latest/devguide/searchable-encryption.html#are-beacons-right-for-me
11+
12+
This example uses a more complex searchable encryption configuration than other examples.
13+
This is intended to demonstrate how to set up a more complicated searchable encryption configuration.
14+
This also walks through some example query expressions one can use to search their encrypted data.
15+
16+
```
17+
.
18+
├── complexsearchableencryptionexample.go // Main entry point for example
19+
├── beaconconfig.go // Sets up beacons and searchable encryption configuration
20+
├── putrequests.go // PUT requests added to the DDB table
21+
├── queryrequests.go // QUERY requests executed on the DDB table
22+
└── README.md
23+
```

0 commit comments

Comments
 (0)