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

feat: cloudwatch json pattern matching #696

Closed
wants to merge 1 commit into from

Conversation

calebwilson706
Copy link

There was an issue using json pattern matching filters for cloudwatch metrics as this library was wrapping all patterns in double quotes. I have added a way around this using a boolean flag to determine whether your pattern is for json logs.

@coveralls
Copy link

Pull Request Test Coverage Report for Build 3280833841

  • 0 of 4 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.3%) to 99.463%

Totals Coverage Status
Change from base Build 3261933059: -0.3%
Covered Lines: 607
Relevant Lines: 607

💛 - Coveralls

@coveralls
Copy link

Pull Request Test Coverage Report for Build 3280833841

  • 4 of 4 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.3%) to 99.463%

Totals Coverage Status
Change from base Build 3261933059: -0.3%
Covered Lines: 607
Relevant Lines: 607

💛 - Coveralls

@erezrokah
Copy link
Owner

Thanks for the PR @calebwilson706, I'm wondering if we should just drop the quoting altogether WDYT?
Then consumers can decide to do the quoting on their end if they need to.

That would be a breaking change so released under v3, but I think it should be fairly easy to migrate

@calebwilson706
Copy link
Author

Thanks for the PR @calebwilson706, I'm wondering if we should just drop the quoting altogether WDYT? Then consumers can decide to do the quoting on their end if they need to.

That would be a breaking change so released under v3, but I think it should be fairly easy to migrate

Yeah we could just do that, the breaking change was what put me off but if you're happy enough to do that then go for it 👍🏻

@erezrokah
Copy link
Owner

erezrokah commented Oct 21, 2022

Yeah we could just do that, the breaking change was what put me off but if you're happy enough to do that then go for it 👍🏻

I didn't give it enough thought when I initially wrote that code. I think it makes sense to pass the pattern as is

@erezrokah
Copy link
Owner

Thanks @calebwilson706 for the PR and everyone who 👍 v3 doesn't do the quoting anymore and leaves it up to the user

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants