Skip to content
This repository has been archived by the owner on Mar 9, 2023. It is now read-only.

Commit

Permalink
Merge pull request #105 from srinandan/issue104
Browse files Browse the repository at this point in the history
fixes incorrect connector para #104
  • Loading branch information
srinandan authored Jan 17, 2023
2 parents 43a91c5 + 31f32b4 commit 3908d96
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
24 changes: 12 additions & 12 deletions client/integrations/integrations.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,15 +109,15 @@ type parameterInternal struct {
}

type parameterExternal struct {
Key string `json:"key,omitempty"`
DataType string `json:"dataType,omitempty"`
DefaultValue valueType `json:"defaultValue,omitempty"`
Name string `json:"name,omitempty"`
IsTransient bool `json:"isTransient,omitempty"`
InputOutputType string `json:"inputOutputType,omitempty"`
Producer string `json:"producer,omitempty"`
Searchable bool `json:"searchable,omitempty"`
JsonSchema string `json:"jsonSchema,omitempty"`
Key string `json:"key,omitempty"`
DataType string `json:"dataType,omitempty"`
DefaultValue *valueType `json:"defaultValue,omitempty"`
Name string `json:"name,omitempty"`
IsTransient bool `json:"isTransient,omitempty"`
InputOutputType string `json:"inputOutputType,omitempty"`
Producer string `json:"producer,omitempty"`
Searchable bool `json:"searchable,omitempty"`
JsonSchema string `json:"jsonSchema,omitempty"`
}

type producedBy struct {
Expand Down Expand Up @@ -147,10 +147,10 @@ type taskconfig struct {
NextTasksExecutionPolicy string `json:"nextTasksExecutionPolicy,omitempty"`
TaskExecutionStrategy string `json:"taskExecutionStrategy,omitempty"`
JsonValidationOption string `json:"jsonValidationOption,omitempty"`
SuccessPolicy successPolicy `json:"successPolicy,omitempty"`
SuccessPolicy *successPolicy `json:"successPolicy,omitempty"`
TaskTemplate string `json:"taskTemplate,omitempty"`
FailurePolicy failurePolicy `json:"failurePolicy,omitempty"`
SynchronousCallFailurePolicy failurePolicy `json:"synchronousCallFailurePolicy,omitempty"`
FailurePolicy *failurePolicy `json:"failurePolicy,omitempty"`
SynchronousCallFailurePolicy *failurePolicy `json:"synchronousCallFailurePolicy,omitempty"`
}

type eventparameter struct {
Expand Down
10 changes: 5 additions & 5 deletions client/integrations/overrides.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ type connectiondetails struct {
}

type connectionparams struct {
ServiceName string `json:"serviceName,omitempty"`
ConnectionName string `json:"connectionName,omitempty"`
ConnectionVersion string `json:"connectionVersion,omitempty"`
ServiceName string `json:"serviceName,omitempty"`
ConnectionName string `json:"connectionName,omitempty"`
ConnectorVersion string `json:"connectorVersion,omitempty"`
}

const pubsubTrigger = "cloud_pubsub_external_trigger/projects/cloud-crm-eventbus-cpsexternal/subscriptions/"
Expand Down Expand Up @@ -134,7 +134,7 @@ func mergeOverrides(eversion integrationVersionExternal, o overrides, supressWar
}

cd.Connection.ConnectionName = newcp.ConnectionName
cd.Connection.ConnectionVersion = newcp.ConnectionVersion
cd.Connection.ConnectorVersion = newcp.ConnectorVersion
cd.Connection.ServiceName = newcp.ServiceName

jsonValue, err := stringifyValue(cd)
Expand Down Expand Up @@ -221,7 +221,7 @@ func getNewConnectionParams(connectionName string, connectionLocation string) (c
return cp, err
}

cp.ConnectionVersion = fmt.Sprintf("%v", connectionVersionResponse["connectorVersion"])
cp.ConnectorVersion = fmt.Sprintf("%v", connectionVersionResponse["connectorVersion"])
cp.ServiceName = fmt.Sprintf("%v", connectionVersionResponse["serviceDirectory"])
cp.ConnectionName = fmt.Sprintf("%v", connectionVersionResponse["name"])

Expand Down

0 comments on commit 3908d96

Please sign in to comment.