You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/10/02 18:29:22 UTC

[GitHub] [flink] sjwiesman opened a new pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

sjwiesman opened a new pull request #13535:
URL: https://github.com/apache/flink/pull/13535


   ## What is the purpose of the change
   
   DataGen source DECIMAL always returns null
   
   
   ## Brief change log
   
   Use longs as the base generator to avoid precision issues. 
   
   ## Verifying this change
   
   UT
   
   ## Does this pull request potentially affect one of the following parts:
   No
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (yes / **no**)
     - If yes, how is the feature documented? (not applicable / docs / JavaDocs / **not documented**)
   


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273) 
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273) 
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     }, {
       "hash" : "20d49a0147e2cf2ff859d9e9c4f138976288df1e",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "20d49a0147e2cf2ff859d9e9c4f138976288df1e",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277) 
   * 20d49a0147e2cf2ff859d9e9c4f138976288df1e UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] sjwiesman commented on a change in pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
sjwiesman commented on a change in pull request #13535:
URL: https://github.com/apache/flink/pull/13535#discussion_r501158416



##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);
+		this.precision = precision;
+		this.scale = scale;
+		this.min = Math.min(-1 * largest, min);
+		this.max = Math.min(largest, max);
+		this.fmt = "%" + precision + "." + scale + "f";
+	}
+
+	@Override
+	public void open(String name, FunctionInitializationContext context, RuntimeContext runtimeContext) throws Exception {
+	}
+
+	@Override
+	public boolean hasNext() {
+		return true;
+	}
+
+	@Override
+	public DecimalData next() {
+		String value = String.format(fmt, ThreadLocalRandom.current().nextDouble(min, max));
+
+		BigDecimal decimal = new BigDecimal(value.trim(), new MathContext(precision, RoundingMode.DOWN));

Review comment:
       yes




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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4c4eecbedcc340b9d19ba499053c8a0196c8a474 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273) 
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     }, {
       "hash" : "20d49a0147e2cf2ff859d9e9c4f138976288df1e",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "20d49a0147e2cf2ff859d9e9c4f138976288df1e",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277) 
   * 20d49a0147e2cf2ff859d9e9c4f138976288df1e UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] knaufk commented on a change in pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
knaufk commented on a change in pull request #13535:
URL: https://github.com/apache/flink/pull/13535#discussion_r501146816



##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);
+		this.precision = precision;
+		this.scale = scale;
+		this.min = Math.min(-1 * largest, min);
+		this.max = Math.min(largest, max);
+		this.fmt = "%" + precision + "." + scale + "f";
+	}
+
+	@Override
+	public void open(String name, FunctionInitializationContext context, RuntimeContext runtimeContext) throws Exception {
+	}
+
+	@Override
+	public boolean hasNext() {
+		return true;
+	}
+
+	@Override
+	public DecimalData next() {
+		String value = String.format(fmt, ThreadLocalRandom.current().nextDouble(min, max));
+
+		BigDecimal decimal = new BigDecimal(value.trim(), new MathContext(precision, RoundingMode.DOWN));

Review comment:
       ```suggestion
   		BigDecimal decimal = new BigDecimal(ThreadLocalRandom.current().nextDouble(min, max), new MathContext(precision, RoundingMode.DOWN));
   ```

##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);

Review comment:
       ```suggestion
   		double largest = Math.pow(10,precision-scale) - Math.pow(10,-scale);
   ```

##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);
+		this.precision = precision;
+		this.scale = scale;
+		this.min = Math.min(-1 * largest, min);
+		this.max = Math.min(largest, max);
+		this.fmt = "%" + precision + "." + scale + "f";

Review comment:
       ```suggestion
   ```

##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);
+		this.precision = precision;
+		this.scale = scale;
+		this.min = Math.min(-1 * largest, min);
+		this.max = Math.min(largest, max);
+		this.fmt = "%" + precision + "." + scale + "f";
+	}
+
+	@Override
+	public void open(String name, FunctionInitializationContext context, RuntimeContext runtimeContext) throws Exception {
+	}
+
+	@Override
+	public boolean hasNext() {
+		return true;
+	}
+
+	@Override
+	public DecimalData next() {
+		String value = String.format(fmt, ThreadLocalRandom.current().nextDouble(min, max));
+
+		BigDecimal decimal = new BigDecimal(value.trim(), new MathContext(precision, RoundingMode.DOWN));

Review comment:
       Doesn't this also work like that?

##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;

Review comment:
       ```suggestion
   ```

##########
File path: flink-table/flink-table-api-java-bridge/src/test/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGeneratorTest.java
##########
@@ -0,0 +1,64 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.table.data.DecimalData;
+
+import org.junit.Assert;
+import org.junit.Test;
+
+import static org.hamcrest.Matchers.equalTo;
+import static org.hamcrest.Matchers.lessThanOrEqualTo;
+
+/**
+ * Tests that the data generator is valid for every combination of precision and scale.
+ */
+public class DecimalDataRandomGeneratorTest {
+
+	@Test
+	public void testGeneratesNonNullValues() {
+		for (int precision = 1; precision <= 38; precision++) {
+			for (int scale = 1; scale <= precision; scale++) {

Review comment:
       ```suggestion
   			for (int scale = 0; scale <= precision; scale++) {
   ```

##########
File path: flink-table/flink-table-api-java-bridge/src/main/java/org/apache/flink/table/factories/datagen/types/DecimalDataRandomGenerator.java
##########
@@ -0,0 +1,91 @@
+/*
+ * 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.flink.table.factories.datagen.types;
+
+import org.apache.flink.api.common.functions.RuntimeContext;
+import org.apache.flink.runtime.state.FunctionInitializationContext;
+import org.apache.flink.streaming.api.functions.source.datagen.DataGenerator;
+import org.apache.flink.table.data.DecimalData;
+
+import java.math.BigDecimal;
+import java.math.MathContext;
+import java.math.RoundingMode;
+import java.util.concurrent.ThreadLocalRandom;
+
+/**
+ * Generates random {@link DecimalData} values.
+ */
+public class DecimalDataRandomGenerator implements DataGenerator<DecimalData> {
+
+	private final int precision;
+
+	private final int scale;
+
+	private final double min;
+
+	private final double max;
+
+	private final String fmt;
+
+	public DecimalDataRandomGenerator(int precision, int scale, double min, double max) {
+		double largest = largestValue(precision, scale);
+		this.precision = precision;
+		this.scale = scale;
+		this.min = Math.min(-1 * largest, min);
+		this.max = Math.min(largest, max);
+		this.fmt = "%" + precision + "." + scale + "f";
+	}
+
+	@Override
+	public void open(String name, FunctionInitializationContext context, RuntimeContext runtimeContext) throws Exception {
+	}
+
+	@Override
+	public boolean hasNext() {
+		return true;
+	}
+
+	@Override
+	public DecimalData next() {
+		String value = String.format(fmt, ThreadLocalRandom.current().nextDouble(min, max));
+
+		BigDecimal decimal = new BigDecimal(value.trim(), new MathContext(precision, RoundingMode.DOWN));
+		return DecimalData.fromBigDecimal(decimal, precision, scale);
+	}
+
+	/**
+	 * Finds the largest valid number of the given precision and range.
+	 */
+	private static double largestValue(int precision, int scale) {
+		StringBuilder builder = new StringBuilder();
+		if (precision == scale) {
+			builder.append("0.");
+		}
+
+		for (int i = 0; i < precision; i++) {
+			if (scale != 0 && precision != scale && i + scale == precision) {
+				builder.append(".");
+			}
+
+			builder.append(9);
+		}
+
+		return Double.parseDouble(builder.toString());
+	}

Review comment:
       ```suggestion
   ```




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



[GitHub] [flink] knaufk merged pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
knaufk merged pull request #13535:
URL: https://github.com/apache/flink/pull/13535


   


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     }, {
       "hash" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277",
       "triggerID" : "b79adda4c4eae4533e7d521b0c52b94f25db4075",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * b79adda4c4eae4533e7d521b0c52b94f25db4075 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7277) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7273) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "505ec8554bfb64d4f53a9f619ffc0729e3e645f3",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   * 505ec8554bfb64d4f53a9f619ffc0729e3e645f3 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] knaufk merged pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
knaufk merged pull request #13535:
URL: https://github.com/apache/flink/pull/13535


   


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



[GitHub] [flink] flinkbot commented on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4c4eecbedcc340b9d19ba499053c8a0196c8a474 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4c4eecbedcc340b9d19ba499053c8a0196c8a474 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172) 
   * bd5834786fbff909ae1a20c5045c0750f63adc4e UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     }, {
       "hash" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "4ed984adbb753d9287a4d5d71d8f2d149f86bba0",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   * 4ed984adbb753d9287a4d5d71d8f2d149f86bba0 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 4c4eecbedcc340b9d19ba499053c8a0196c8a474 Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172) 
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] sjwiesman commented on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
sjwiesman commented on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-705166886


   @knaufk thanks for taking a look, I've pushed a fix that should address all of your comments. 


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



[GitHub] [flink] flinkbot edited a comment on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702896138


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7172",
       "triggerID" : "4c4eecbedcc340b9d19ba499053c8a0196c8a474",
       "triggerType" : "PUSH"
     }, {
       "hash" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177",
       "triggerID" : "bd5834786fbff909ae1a20c5045c0750f63adc4e",
       "triggerType" : "PUSH"
     }, {
       "hash" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271",
       "triggerID" : "97e855d306d15d90259b65d3db38b7a19c62c6e9",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * bd5834786fbff909ae1a20c5045c0750f63adc4e Azure: [FAILURE](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7177) 
   * 97e855d306d15d90259b65d3db38b7a19c62c6e9 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=7271) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


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



[GitHub] [flink] flinkbot commented on pull request #13535: [FLINK-19496][table] DataGen source DECIMAL always returns null

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #13535:
URL: https://github.com/apache/flink/pull/13535#issuecomment-702892022


   Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community
   to review your pull request. We will use this comment to track the progress of the review.
   
   
   ## Automated Checks
   Last check on commit 4c4eecbedcc340b9d19ba499053c8a0196c8a474 (Fri Oct 02 18:31:44 UTC 2020)
   
   **Warnings:**
    * No documentation files were touched! Remember to keep the Flink docs up to date!
   
   
   <sub>Mention the bot in a comment to re-run the automated checks.</sub>
   ## Review Progress
   
   * ❓ 1. The [description] looks good.
   * ❓ 2. There is [consensus] that the contribution should go into to Flink.
   * ❓ 3. Needs [attention] from.
   * ❓ 4. The change fits into the overall [architecture].
   * ❓ 5. Overall code [quality] is good.
   
   Please see the [Pull Request Review Guide](https://flink.apache.org/contributing/reviewing-prs.html) for a full explanation of the review process.<details>
    The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot approve description` to approve one or more aspects (aspects: `description`, `consensus`, `architecture` and `quality`)
    - `@flinkbot approve all` to approve all aspects
    - `@flinkbot approve-until architecture` to approve everything until `architecture`
    - `@flinkbot attention @username1 [@username2 ..]` to require somebody's attention
    - `@flinkbot disapprove architecture` to remove an approval you gave earlier
   </details>


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