GitHub user weiqingy opened a pull request:
https://github.com/apache/samza/pull/732
SAMZA-1938: Support use cases to run multiple sql statements in one Samza
job
## What changes were proposed in this pull request?
This PR is to support the following user scenarios:
1. support users to run multiple Sql statements in the same job.
- sql1 = "Insert into testavro.simpleOutputTopic select * from
testavro.SIMPLE1";
- sql2 = "Insert into testavro.SIMPLE3 select * from testavro.SIMPLE2";
2. Support fan-out use case. For example,
- sql1 = "Insert into testavro.SIMPLE2 select * from testavro.SIMPLE1";
- sql2 = "Insert into testavro.SIMPLE3 select * from testavro.SIMPLE1";
3. Support fan-in use case. For example,
- sql1 = "Insert into testavro.simpleOutputTopic select * from
testavro.SIMPLE2";
- sql2 = "Insert into testavro.simpleOutputTopic select * from
testavro.SIMPLE1";
This PR makes the information about `SystemDescriptors`, `MessageStream of
input sources` and `OutputStream` stored in `QueryTranslator`. The reason is
that those information belongs to the job and each job has only one
`QueryTranslator` object.
## How was this patch tested?
1. Add unit tests
2. Testing in Samza SQL shell.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/weiqingy/samza SAMZA-1938
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/samza/pull/732.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #732
----
commit aa12c43a828cdf3343307ac11655807a78a950d5
Author: Weiqing Yang <yangweiqing001@...>
Date: 2018-10-16T18:46:59Z
SAMZA-1938: Support use cases to run multiple sql statements in one Samza
job
----
---