Skip to content

Commit

Permalink
feat: add extra streams
Browse files Browse the repository at this point in the history
  • Loading branch information
Ishan Arya committed Sep 30, 2024
1 parent 2eb0f56 commit 9df3622
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
11 changes: 6 additions & 5 deletions modules/flink/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,12 @@ type Influx struct {
}

type Config struct {
KubeNamespace string `json:"kube_namespace,omitempty"`
Influx Influx `json:"influx,omitempty"`
SinkKafkaStream string `json:"sink_kafka_stream,omitempty"`
PrometheusURL string `json:"prometheus_url,omitempty"`
FlinkName string `json:"flink_name,omitempty"`
KubeNamespace string `json:"kube_namespace,omitempty"`
Influx Influx `json:"influx,omitempty"`
SinkKafkaStream string `json:"sink_kafka_stream,omitempty"`
PrometheusURL string `json:"prometheus_url,omitempty"`
FlinkName string `json:"flink_name,omitempty"`
ExtraStreams []string `json:"extra_streams,omitempty"`
}

func readConfig(_ resource.Resource, confJSON json.RawMessage, dc driverConf) (*Config, error) {
Expand Down
1 change: 1 addition & 0 deletions modules/flink/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ type Output struct {
SinkKafkaStream string `json:"sink_kafka_stream,omitempty"`
PrometheusURL string `json:"prometheus_url,omitempty"`
FlinkName string `json:"flink_name,omitempty"`
ExtraStreams []string `json:"extra_streams,omitempty"`
}

func readOutputData(exr module.ExpandedResource) (*Output, error) {
Expand Down
1 change: 1 addition & 0 deletions modules/flink/driver_output.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ func (fd *flinkDriver) Output(ctx context.Context, exr module.ExpandedResource)
output.SinkKafkaStream = conf.SinkKafkaStream
output.PrometheusURL = conf.PrometheusURL
output.FlinkName = conf.FlinkName
output.ExtraStreams = conf.ExtraStreams

return modules.MustJSON(output), nil
}

0 comments on commit 9df3622

Please sign in to comment.