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

fix: add action rendered trace for s3 in aggregated mode #13100

Conversation

kjellwinblad
Copy link
Contributor

Fixes:
https://emqx.atlassian.net/browse/EMQX-12429

Manually tested

Release version: v/e5.?

Summary

PR Checklist

Please convert it to a draft if any of the following conditions are not met. Reviewers may skip over until all the items are checked:

  • [] Added tests for the changes
  • [] Added property-based tests for code which performs user input validation
  • [] Changed lines covered in coverage report
  • [] Change log has been added to changes/(ce|ee)/(feat|perf|fix|breaking)-<PR-id>.en.md files
  • [] For internal contributor: there is a jira ticket to track this change
  • [] Created PR to emqx-docs if documentation update is required, or link to a follow-up jira ticket
  • [] Schema changes are backward compatible

@kjellwinblad kjellwinblad requested a review from a team as a code owner May 23, 2024 08:22
@@ -372,6 +379,13 @@ run_aggregated_upload(InstId, Records, #{aggreg_id := AggregId}) ->
{error, {unrecoverable_error, Reason}}
end.

render_records(Records) ->
try
[unicode:characters_to_binary(R) || R <- Records]
Copy link
Contributor

Choose a reason for hiding this comment

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

Q: Records are maps 99.9% of time, productions of a Rule SQL expression, to be more specific. I wonder why do we attempt to stringify them like that first?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You are right. This was done for non-aggregate mode so I assumed we should do the same for aggregate mode as well but I see now that this is incorrect. In non-aggregate mode we render a template. I will fix. Btw, I accidentally pushed a commit for another issue to this PR. Do you think you can review that one as well so we can merge both with the same PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed the formatting here: 89b47e8

This commit makes sure that the trace setting for payload encode works
even when the payload is in a nested structure or when the payload key
is a binary instead of an atom.

Fixes:
https://emqx.atlassian.net/browse/EMQX-12424
Copy link
Contributor

@keynslug keynslug left a comment

Choose a reason for hiding this comment

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

Seems reasonable! Not too confident about fb7688a due to lack of context.

@kjellwinblad kjellwinblad merged commit 0e5b02c into emqx:release-57 May 23, 2024
171 checks passed
@emqxqa
Copy link

emqxqa commented May 23, 2024

TestExecution

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.

None yet

3 participants