[
https://issues.apache.org/jira/browse/BEAM-9072?focusedWorklogId=376668&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-376668
]
ASF GitHub Bot logged work on BEAM-9072:
----------------------------------------
Author: ASF GitHub Bot
Created on: 24/Jan/20 00:48
Start Date: 24/Jan/20 00:48
Worklog Time Spent: 10m
Work Description: TheNeuralBit commented on pull request #10440:
[BEAM-9072] [SQL] DataStoreV1 IO connector
URL: https://github.com/apache/beam/pull/10440#discussion_r370429316
##########
File path:
sdks/java/extensions/sql/src/main/java/org/apache/beam/sdk/extensions/sql/impl/schema/BeamTableUtils.java
##########
@@ -137,6 +138,12 @@ public static Object autoCastField(Schema.Field field,
Object rawObj) {
throw new UnsupportedOperationException(
String.format("Column type %s is not supported yet!", type));
}
+ } else if (type.getTypeName().isPrimitiveType()) {
+ if (TypeName.BYTES.equals(type.getTypeName()) && rawObj instanceof
ByteString) {
+ return ((ByteString) rawObj).getBytes();
+ }
+ throw new UnsupportedOperationException(
+ String.format("Column type %s is not supported yet!", type));
Review comment:
@11moon11 it looks like this broke PubsubJsonIT:
https://builds.apache.org/job/beam_PostCommit_SQL/3812
```
java.lang.UnsupportedOperationException: Column type
FieldType{typeName=BOOLEAN, nullable=true, logicalType=null,
collectionElementType=null, mapKeyType=null, mapValueType=null, rowSchema=null,
metadata={}} is not supported yet!
at
org.apache.beam.sdk.extensions.sql.impl.schema.BeamTableUtils.autoCastField(BeamTableUtils.java:146)
at
org.apache.beam.sdk.extensions.sql.impl.rel.BeamValuesRel.lambda$tupleToRow$0(BeamValuesRel.java:95)
at java.util.stream.IntPipeline$4$1.accept(IntPipeline.java:250)
```
Do you think it would be easy to fix or should we roll back?
----------------------------------------------------------------
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: 376668)
Time Spent: 6h 40m (was: 6.5h)
> [SQL] Add support for Datastore source
> --------------------------------------
>
> Key: BEAM-9072
> URL: https://issues.apache.org/jira/browse/BEAM-9072
> Project: Beam
> Issue Type: New Feature
> Components: dsl-sql
> Reporter: Kirill Kozlov
> Assignee: Kirill Kozlov
> Priority: Major
> Fix For: 2.20.0
>
> Time Spent: 6h 40m
> Remaining Estimate: 0h
>
> * Create a Datastore table and table provider
> * Conversion between Datastore and Beam data types
> * Implement buildIOReader
> * Implement buildIOWrite
> * Implement getTableStatistics
> Doc:
> [https://docs.google.com/document/d/1FxuEGewJ3GPDl0IKglfOYf1edwa2m_wryFZYRMpRNbA/edit?pli=1]
--
This message was sent by Atlassian Jira
(v8.3.4#803005)