[ 
https://issues.apache.org/jira/browse/BEAM-9894?focusedWorklogId=437228&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-437228
 ]

ASF GitHub Bot logged work on BEAM-9894:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 27/May/20 03:21
            Start Date: 27/May/20 03:21
    Worklog Time Spent: 10m 
      Work Description: pabloem commented on a change in pull request #11794:
URL: https://github.com/apache/beam/pull/11794#discussion_r430612172



##########
File path: 
sdks/java/io/snowflake/src/main/java/org/apache/beam/sdk/io/snowflake/CSVSink.java
##########
@@ -0,0 +1,67 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.beam.sdk.io.snowflake;
+
+import java.io.BufferedWriter;
+import java.io.IOException;
+import java.io.OutputStreamWriter;
+import java.io.PrintWriter;
+import java.nio.channels.Channels;
+import java.nio.channels.WritableByteChannel;
+import java.nio.charset.Charset;
+import java.util.List;
+import org.apache.beam.sdk.io.FileIO;
+import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.base.Joiner;
+
+/** Implementation of {@link org.apache.beam.sdk.io.FileIO.Sink} for writing 
CSV. */
+public class CSVSink implements FileIO.Sink<String> {

Review comment:
       I took only a very superficial look. Are you using CSV file imports to 
write to Snowflake? I would be concerned about types being properly encoded in 
the CSV (big integers, floats, bytes, date/time types, strings with 
newlines/quotes). Have you already considered how to deal with all types?




----------------------------------------------------------------
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:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 437228)
    Time Spent: 50m  (was: 40m)

> Add batch SnowflakeIO.Write to Java SDK
> ---------------------------------------
>
>                 Key: BEAM-9894
>                 URL: https://issues.apache.org/jira/browse/BEAM-9894
>             Project: Beam
>          Issue Type: New Feature
>          Components: io-ideas
>            Reporter: Dariusz Aniszewski
>            Priority: P2
>          Time Spent: 50m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to