-
Notifications
You must be signed in to change notification settings - Fork 113
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: feature flag http dest example #3933
base: develop
Are you sure you want to change the base?
Conversation
src/v0/destinations/webhook/utils.js
Outdated
case XML: | ||
return { payload: { payload: getXMLPayload(payload) }, contentTypeSimplified }; | ||
case FORM: | ||
return { payload, contentTypeSimplified }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return { payload, contentTypeSimplified }; | |
return { getFORMPayload(payload), contentTypeSimplified }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't have to convert this into FORMPayload ourselves as rudder-server
takes care of it.
Follow this link to see what rudder-server is doing: https://github.com/rudderlabs/rudder-server/blob/f22e8f4bb61893af132f3f4386155c83c695fd51/router/network.go#L124
But I see the issue here, we need to flatten the json for rudder-server to properly convert it into form-values
I think a simple flattening will do the job here @krishna2020
integrations: { | ||
All: true, | ||
}, | ||
message_id: 'a80f82be-9bdc-4a9f-b2a5-15621ee41df8', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test case can be made readable by restricting only to necessary fields in the payload
Quality Gate failedFailed conditions See analysis details on SonarQube Cloud Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE |
What are the changes introduced in this PR?
dest_transformer_webhook_form_support
. New feature flag sdk is used to achieve this.This is only a draft and will be updated to use better naming convention for feature flag and better imports for cdk/v2/webhook.
What is the related Linear task?
Resolves INT-2991
Please explain the objectives of your changes below
To experiment with the new feature flag sdk and perform end-to-end testing.
Any changes to existing capabilities/behaviour, mention the reason & what are the changes ?
webhook destination now respects content-type headers
Any new dependencies introduced with this change?
feature-flag-sdk
Any new generic utility introduced or modified. Please explain the changes.
N/A
Any technical or performance related pointers to consider with the change?
How efficient is feature-flag-sdk?
@coderabbitai review
Developer checklist
My code follows the style guidelines of this project
No breaking changes are being introduced.
All related docs linked with the PR?
All changes manually tested?
Any documentation changes needed with this change?
Is the PR limited to 10 file changes?
Is the PR limited to one linear task?
Are relevant unit and component test-cases added in new readability format?
Reviewer checklist
Is the type of change in the PR title appropriate as per the changes?
Verified that there are no credentials or confidential data exposed with the changes.