You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Vanus Functions are a series of pre-built functions worked within Vanus transformer. By choosing a function, users can specify the way that events will be changed.
It will be a good start if you decide to contribute to Vanus codes.
Details
Function name: check_custom_values
Args
sourceJsonPath - The name of an existing column.
customValue - Custom value to check
targetJsonPath The name of the new column to be created.
trueFlagReplacement - custom string if value equal custom value
falseFlagReplacement - Custom string if value doesn't equal custom value
Description
The function is used to check if the source JSON path contains the customValue or not. If it contains that value, the trueFlagReplacement will be assigned to the target JSON path. If it doesn't, the falseFlagReplacement will be assigned to the target JSON path.
Create check_custom_values.go under internal/primitive/transform/action/strings, and then implement the function.
Create check_custom_values .go under internal/primitive/transform/action/strings for unit test.
Register your function in internal/primitive/transform/runtime/init.go.
Submit your PR
Contribution points
Each issue counts specific points based on its difficulty. Contributors earn the corresponding points if they solve that issue. Contribution points are used to describe the contributions contributors have made. They can also be used to get rewards when there are community events.
This issue counts 7 points.
How to claim to solve the issue
If you want to implement this function, please leave a comment in this issue like:
I'd like to implement this function, please assign this issue to me.
Vanus community will assign the issue to you on time.
The text was updated successfully, but these errors were encountered:
Motivation
Vanus Functions are a series of pre-built functions worked within Vanus transformer. By choosing a function, users can specify the way that events will be changed.
It will be a good start if you decide to contribute to Vanus codes.
Details
Function name: check_custom_values
Args
Description
The function is used to check if the source JSON path contains the customValue or not. If it contains that value, the trueFlagReplacement will be assigned to the target JSON path. If it doesn't, the falseFlagReplacement will be assigned to the target JSON path.
Example
After the function "check_custom_values":
The transformed event should look like this:
How to implement
function-check_custom_values
check_custom_values.go
underinternal/primitive/transform/action/strings
, and then implement the function.check_custom_values .go
underinternal/primitive/transform/action/strings
for unit test.internal/primitive/transform/runtime/init.go
.Contribution points
Each issue counts specific points based on its difficulty. Contributors earn the corresponding points if they solve that issue. Contribution points are used to describe the contributions contributors have made. They can also be used to get rewards when there are community events.
This issue counts 7 points.
How to claim to solve the issue
If you want to implement this function, please leave a comment in this issue like:
Vanus community will assign the issue to you on time.
The text was updated successfully, but these errors were encountered: