[
https://issues.apache.org/jira/browse/BEAM-3773?focusedWorklogId=110747&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-110747
]
ASF GitHub Bot logged work on BEAM-3773:
----------------------------------------
Author: ASF GitHub Bot
Created on: 11/Jun/18 19:56
Start Date: 11/Jun/18 19:56
Worklog Time Spent: 10m
Work Description: apilloud commented on a change in pull request #5592:
[BEAM-3773] [SQL] Add support for setting PipelineOptions
URL: https://github.com/apache/beam/pull/5592#discussion_r194527918
##########
File path:
sdks/java/extensions/sql/src/main/java/org/apache/beam/sdk/extensions/sql/impl/rel/BeamEnumerableConverter.java
##########
@@ -83,12 +81,25 @@ public Result implement(EnumerableRelImplementor
implementor, Prefer prefer) {
final RelDataType rowType = getRowType();
final PhysType physType =
PhysTypeImpl.of(implementor.getTypeFactory(), rowType,
prefer.preferArray());
- final Expression options = implementor.stash(this.options,
PipelineOptions.class);
final Expression node = implementor.stash((BeamRelNode) getInput(),
BeamRelNode.class);
- list.add(Expressions.call(BeamEnumerableConverter.class, "toEnumerable",
options, node));
+ list.add(Expressions.call(BeamEnumerableConverter.class, "toEnumerable",
node));
return implementor.result(physType, list.toBlock());
}
+ public static Enumerable<Object> toEnumerable(BeamRelNode node) {
+ final PipelineOptions options =
createPipelineOptions(node.getPipelineOptions());
+ return toEnumerable(options, node);
+ }
+
+ private static PipelineOptions createPipelineOptions(Map<String, String>
map) {
+ final String[] args = new String[map.size()];
+ int i = 0;
+ for (Map.Entry<String, String> entry : map.entrySet()) {
Review comment:
I looked into this and spent a few hours prototyping, but gave up after
finding the scope of work involved is non-trivial. `PipelineOptionsFactory`
will require a significant refactor to get this done right.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 110747)
Time Spent: 15h (was: 14h 50m)
> [SQL] Investigate JDBC interface for Beam SQL
> ---------------------------------------------
>
> Key: BEAM-3773
> URL: https://issues.apache.org/jira/browse/BEAM-3773
> Project: Beam
> Issue Type: Improvement
> Components: dsl-sql
> Reporter: Anton Kedin
> Assignee: Andrew Pilloud
> Priority: Major
> Time Spent: 15h
> Remaining Estimate: 0h
>
> JDBC allows integration with a lot of third-party tools, e.g
> [Zeppelin|https://zeppelin.apache.org/docs/0.7.0/manual/interpreters.html],
> [sqlline|https://github.com/julianhyde/sqlline]. We should look into how
> feasible it is to implement a JDBC interface for Beam SQL
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)