Skip to content

Commit

Permalink
debugging cnm input
Browse files Browse the repository at this point in the history
  • Loading branch information
torimcd committed Jun 4, 2024
1 parent 45c0435 commit e05dd3f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
4 changes: 2 additions & 2 deletions bignbit/save_cnm_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ def process(self):
"""
pobit_audit_bucket = self.config['pobit_audit_bucket']
print(pobit_audit_bucket)
print(self.input.get('cnm_sent'))
print(self.input)

collection_name = self.config['collection']
granule_ur = self.config['granule_ur']

print(collection_name)
print(granule_ur)

cnm_content = self.input
cnm_content = self.input['cnm']
print(cnm_content)

print(cnm_content)
Expand Down
6 changes: 1 addition & 5 deletions bignbit/send_to_gitc.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,9 @@ def process(self):
image_set = ImageSet(**self.input['image_set'])
gitc_id = image_set.name

response_payload = {}
response_payload = self.input.copy()

cnm_message = notify_gitc(image_set, cmr_provider, gitc_id, collection_name)
response_payload['cnm_sent'] = cnm_message

return response_payload
return cnm_message


def notify_gitc(image_set: ImageSet, cmr_provider: str, gitc_id: str, collection_name: str):
Expand Down
3 changes: 2 additions & 1 deletion terraform/state_machine_definition.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,7 @@
"Type": "Task",
"Resource": "arn:aws:states:::lambda:invoke",
"TimeoutSeconds": 86400,
"ResultPath": "$.cnm",
"Next": "SaveCNMMessage"
},
"SaveCNMMessage": {
Expand All @@ -461,7 +462,7 @@
"granule_ur": "{$.granule_ur}",
"pobit_audit_bucket": "${PobitAuditBucket}",
"cumulus_message": {
"input": "{$}"
"input": "{$.payload}"
}
}
}
Expand Down

0 comments on commit e05dd3f

Please sign in to comment.