Error parsing Oauth properties in cncf spec using java sdk #857
Replies: 2 comments
-
@mahith2108 it's a bug, I transferred to this issue here: serverlessworkflow/sdk-java#357 Can you open a PR? |
Beta Was this translation helpful? Give feedback.
0 replies
-
I'm taking the liberty to close the conversation, as @ricardozanini has opened an issue to address the discussed issue. Please, feel free to reopen if need be 😉 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
we are using Java sdk version "4.0.5.Final" and spec version: 0.8 as suggested (https://github.com/serverlessworkflow/sdk-java)
I am trying to define Oauth properties using "auth" field in my spec as follows based on #675
"auth":[
{ "name" : "serviceCloud",
"scheme": "oauth2",
"properties":{
"scopes": ["$$$$XXXMMMMM"],
"audiences":["%%%XXXXXXX"]
}
while parsing the spec using Workflow.fromSource("") I am getting following error.
Could not convert markup to Workflow: Unrecognized field "scopes" (class io.serverlessworkflow.api.auth.BasicAuthDefinition), not marked as ignorable (3 known properties: "password", "username", "metadata"])
at [Source: UNKNOWN; byte offset: #UNKNOWN] (through reference chain: io.serverlessworkflow.api.Workflow["auth"]->io.serverlessworkflow.api.auth.BasicAuthDefinition["scopes"])
we have tried following spec as well but the authDefinition.getOauth() is coming as null.
"auth":[
{ "name" : "serviceCloud",
"scheme": "oauth2",
"oauth":{
"scopes": ["%%%%%X"],
"audiences":["%%%XXXXXX"]
}
@JsonPropertyOrder({"name", "scheme", "basicauth", "bearerauth", "oauth"})
public class AuthDefinition implements Serializable {
Beta Was this translation helpful? Give feedback.
All reactions