Help! We’re having odd APIG issues where one funct...
# help
d
Help! We’re having odd APIG issues where one function is triggering but the other is not. They both
CF -> APIG -> Lambda
but only the first one hits the authorizer and function the other only logs out in APIG but never beyond that. This WORKS
POST /api/event/submit
This does NOT
GET /api/event/submit-prev
This is the behaviour to point traffic to the api from cloudfront
Copy code
cfDistribution.addBehavior('/api/event/*', new cfOrigins.HttpOrigin(eventApiDomain), {
  allowedMethods: cf.AllowedMethods.ALLOW_ALL,
  viewerProtocolPolicy: cf.ViewerProtocolPolicy.REDIRECT_TO_HTTPS,
  cachePolicy: cf.CachePolicy.CACHING_DISABLED,
  compress: false,
})
f
@Dan Van Brunt could it be authorizer caching related? As a sanity check, set the authorizer’s
resultsCacheTtl
to “0 seconds” temporarily.
d
Thanks! yes ended up being that cachedHeaders are get and head by default and we turned off caching…. so the Authorization header wasnt getting there