mirror of
https://github.com/Sea-Haven-Industries/procurement-ingest.git
synced 2026-10-04 11:21:56 +00:00
Compare commits
No commits in common. "9370abf9ab30a8f4cf2d82c7b5d164646f72770a" and "dfd2a7712675298cd4ee7bdefbf824274701149b" have entirely different histories.
9370abf9ab
...
dfd2a77126
2 changed files with 31 additions and 8 deletions
|
|
@ -73,9 +73,7 @@ class PoIngestStack(Stack):
|
|||
command=[
|
||||
"bash",
|
||||
"-c",
|
||||
"pip install --platform manylinux2014_aarch64 --only-binary=:all: "
|
||||
"-r requirements.txt -t /asset-output && "
|
||||
"cp handler.py /asset-output/",
|
||||
"pip install -r requirements.txt -t /asset-output && cp handler.py /asset-output/",
|
||||
],
|
||||
),
|
||||
),
|
||||
|
|
@ -159,8 +157,14 @@ class PoIngestStack(Stack):
|
|||
billing_mode=dynamodb.BillingMode.PAY_PER_REQUEST,
|
||||
removal_policy=RemovalPolicy.RETAIN,
|
||||
)
|
||||
# by-state GSI removed 2026-06-03 (audit M-20): 0 reads in 30d against
|
||||
# 518 WCU of write amplification. Re-add if a state-level query path ships.
|
||||
verified_sites_table.add_global_secondary_index(
|
||||
index_name="by-state",
|
||||
partition_key=dynamodb.Attribute(
|
||||
name="state",
|
||||
type=dynamodb.AttributeType.STRING,
|
||||
),
|
||||
projection_type=dynamodb.ProjectionType.ALL,
|
||||
)
|
||||
|
||||
# --- Site extractor Lambda (DynamoDB Streams → verified-sites) ---
|
||||
site_extractor = lambda_.Function(
|
||||
|
|
|
|||
|
|
@ -44,9 +44,28 @@ class WorkorderIngestStack(Stack):
|
|||
billing_mode=dynamodb.BillingMode.PAY_PER_REQUEST,
|
||||
removal_policy=RemovalPolicy.RETAIN,
|
||||
)
|
||||
# site-code-index and status-index GSIs removed 2026-06-03 (audit M-20):
|
||||
# 0 reads in 30d against ~50k WCU each of write amplification. Re-add if
|
||||
# a site-code or status query path ships.
|
||||
work_orders_table.add_global_secondary_index(
|
||||
index_name="site-code-index",
|
||||
partition_key=dynamodb.Attribute(
|
||||
name="site_code",
|
||||
type=dynamodb.AttributeType.STRING,
|
||||
),
|
||||
sort_key=dynamodb.Attribute(
|
||||
name="updated_at",
|
||||
type=dynamodb.AttributeType.STRING,
|
||||
),
|
||||
)
|
||||
work_orders_table.add_global_secondary_index(
|
||||
index_name="status-index",
|
||||
partition_key=dynamodb.Attribute(
|
||||
name="wo_status",
|
||||
type=dynamodb.AttributeType.STRING,
|
||||
),
|
||||
sort_key=dynamodb.Attribute(
|
||||
name="updated_at",
|
||||
type=dynamodb.AttributeType.STRING,
|
||||
),
|
||||
)
|
||||
|
||||
comments_table = dynamodb.Table(
|
||||
self,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue