[
https://issues.apache.org/jira/browse/BEAM-10669?focusedWorklogId=478103&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-478103
]
ASF GitHub Bot logged work on BEAM-10669:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 02/Sep/20 20:14
Start Date: 02/Sep/20 20:14
Worklog Time Spent: 10m
Work Description: pabloem commented on a change in pull request #12618:
URL: https://github.com/apache/beam/pull/12618#discussion_r482399571
##########
File path:
sdks/java/io/snowflake/src/main/java/org/apache/beam/sdk/io/snowflake/SnowflakeIO.java
##########
@@ -1532,26 +1767,47 @@ public DataSource buildDatasource() {
SnowflakeBasicDataSource basicDataSource = new
SnowflakeBasicDataSource();
basicDataSource.setUrl(buildUrl());
- if (getUsername() != null) {
- basicDataSource.setUser(getUsername());
+ if (isNotEmpty(getOauthToken())) {
+ basicDataSource.setOauthToken(getOauthToken().get());
+ } else if (isNotEmpty(getUsername()) && getPrivateKey() != null) {
+ basicDataSource.setUser(getUsername().get());
+ basicDataSource.setPrivateKey(getPrivateKey());
+ } else if (isNotEmpty(getUsername())
+ && isNotEmpty(getPrivateKeyPassphrase())
+ && isNotEmpty(getRawPrivateKey())) {
+ PrivateKey privateKey =
+ KeyPairUtils.preparePrivateKey(
+ getRawPrivateKey().get(), getPrivateKeyPassphrase().get());
+ basicDataSource.setPrivateKey(privateKey);
+ basicDataSource.setUser(getUsername().get());
+
Review comment:
The only way to 'hide' them would be to remove them from display data.
It's up to you if you'd like to keep it in DD or remove it.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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: 478103)
Time Spent: 7h (was: 6h 50m)
> Add support for Dataflow Templates
> ----------------------------------
>
> Key: BEAM-10669
> URL: https://issues.apache.org/jira/browse/BEAM-10669
> Project: Beam
> Issue Type: Improvement
> Components: io-ideas
> Reporter: Kasia Kucharczyk
> Assignee: Kasia Kucharczyk
> Priority: P2
> Time Spent: 7h
> Remaining Estimate: 0h
>
> It is required to change arguments to ValueProvider type and move all
> functionalities of those parameters to extend methods.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)