-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: minor changes to dynamic label part of label application rule (#…
…234)
- Loading branch information
1 parent
3697588
commit 3b9a335
Showing
7 changed files
with
58 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
...abels-schema-api/src/main/java/org/hypertrace/graphql/label/schema/rule/DynamicLabel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package org.hypertrace.graphql.label.schema.rule; | ||
|
||
import graphql.annotations.annotationTypes.GraphQLDescription; | ||
import graphql.annotations.annotationTypes.GraphQLField; | ||
import graphql.annotations.annotationTypes.GraphQLName; | ||
import graphql.annotations.annotationTypes.GraphQLNonNull; | ||
import java.util.List; | ||
|
||
@GraphQLName(DynamicLabel.TYPE_NAME) | ||
public interface DynamicLabel { | ||
String TYPE_NAME = "DynamicLabel"; | ||
|
||
String EXPRESSION_KEY = "expression"; | ||
String TOKEN_EXTRACTION_RULES_KEY = "tokenExtractionRules"; | ||
|
||
@GraphQLField | ||
@GraphQLDescription( | ||
"Expression definition to generate dynamic labels. Ex: \"${token1}_${token2}\"") | ||
@GraphQLName(EXPRESSION_KEY) | ||
@GraphQLNonNull | ||
String expression(); | ||
|
||
@GraphQLField | ||
@GraphQLDescription( | ||
"Rules to extract token from attribute values. These values will replace tokens in the expression.") | ||
@GraphQLNonNull | ||
@GraphQLName(TOKEN_EXTRACTION_RULES_KEY) | ||
List<TokenExtractionRule> tokenExtractionRules(); | ||
} |
24 changes: 0 additions & 24 deletions
24
...ma-api/src/main/java/org/hypertrace/graphql/label/schema/rule/DynamicLabelExpression.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters