Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Websockets: fix passing log group ARN #6310

Merged
merged 1 commit into from
Jul 1, 2019

Conversation

christophgysin
Copy link
Contributor

@christophgysin christophgysin commented Jun 26, 2019

The log group ARN contains a trailing ":*" that seems to cause
deployment to fail. Instead, generate the ARN with the trailing
wildcard.

What did you implement:

Closes #6304

How did you implement it:

Construct the log group ARN using Fn::Sub.

How can we verify it:

See issue referenced above.

Todos:

Note: Run npm run test-ci to run all validation checks on proposed changes

  • Write tests and confirm existing functionality is not broken.
    Validate via npm test
  • Write documentation
  • Ensure there are no lint errors.
    Validate via npm run lint-updated
    Note: Some reported issues can be automatically fixed by running npm run lint:fix
  • Ensure introduced changes match Prettier formatting.
    Validate via npm run prettier-check-updated
    Note: All reported issues can be automatically fixed by running npm run prettify-updated
  • Make sure code coverage hasn't dropped
  • Provide verification config / commands / resources
  • Enable "Allow edits from maintainers" for this PR
  • Update the messages below

Is this ready for review?: YES
Is it a breaking change?: NO

The log group ARN contains a trailing ":*" that seems to cause
deployment to fail. Instead, generate the ARN with the trailing
wildcard.

fixes serverless#6304
Copy link
Contributor

@pmuens pmuens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @christophgysin thanks for working on this. I tried to reproduce this bug running our latest v1.46.0 version. (Un)fortunately I was not able to reproduce it.

Is there any additional service info you can provide (aside from that written down in the issue description) so that we can test it on our end?

Thanks in advance.


Edit:

Here's the serverless.yml I've used:

service: test

provider:
  name: aws
  runtime: nodejs10.x
  logs:
    websocket: true

functions:
  test:
    handler: handler.hello
    events:
      - websocket: $connect

@pmuens pmuens changed the title websockets: fix passing log group ARN Websockets: fix passing log group ARN Jun 28, 2019
@christophgysin
Copy link
Contributor Author

@pmuens I can reproduce it also with v1.46.0. It seems that it only fails if you try to enable the logs on a service that is already deployed.

Can you try to disable the logs, deploy, enable them, and deploy again?

Copy link
Contributor

@pmuens pmuens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for following-up @christophgysin 👍

I was able to reproduce the issue and can confirm that your PR fixes the issue. LGTM :shipit:

@pmuens pmuens merged commit 35e81fa into serverless:master Jul 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enabling websocket logs fails deployment
2 participants