Skip to content

Commit

Permalink
Changes the KV bucket sourcing code to use the SubjectTransforms array
Browse files Browse the repository at this point in the history
  • Loading branch information
jnmoyne authored and piotrpio committed Sep 20, 2023
1 parent 7d66f4a commit 06bbf5f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions kv.go
Original file line number Diff line number Diff line change
Expand Up @@ -442,8 +442,7 @@ func (js *js) CreateKeyValue(cfg *KeyValueConfig) (KeyValue, error) {
}

if ss.External == nil || sourceBucketName != cfg.Bucket {
ss.FilterSubject = fmt.Sprintf(kvSubjectsTmpl, sourceBucketName)
ss.SubjectTransformDest = fmt.Sprintf(kvSubjectsTmpl, cfg.Bucket)
ss.SubjectTransforms = []SubjectTransformConfig{{Source: fmt.Sprintf(kvSubjectsTmpl, sourceBucketName), Destination: fmt.Sprintf(kvSubjectsTmpl, cfg.Bucket)}}
}
scfg.Sources = append(scfg.Sources, ss)
}
Expand Down

0 comments on commit 06bbf5f

Please sign in to comment.