cisagov / crossfeed

External monitoring for organization assets
https://docs.crossfeed.cyber.dhs.gov
Creative Commons Zero v1.0 Universal
366 stars 54 forks source link

Fix Truncated Logs #2386

Open aloftus23 opened 10 months ago

aloftus23 commented 10 months ago

🐛 Summary

Make sure there are no logs going to Cloudwatch that are too long to be stored and show the [TRUNCATED] message.

This is a high priority issue since we are losing logs.

aloftus23 commented 10 months ago

At this time there is not a reasonable solution to this problem. AWS doesn't support API gateway log messages greater than 1024 bytes. There are solutions in the link below that require wrapping the gateway in Lambda functions which is not recommended.

https://stackoverflow.com/questions/54097769/aws-cloudwatch-is-truncating-logs

https://stackoverflow.com/questions/61241488/log-requests-responses-in-api-gateway-through-labmbda-proxy

https://repost.aws/knowledge-center/api-gateway-logs

aloftus23 commented 10 months ago

Reopening as this is a required feature