Skip to content

Commit c4a8144

Browse files
author
dapeng
committed
Merge branch 'hotfix_1.8_3.10.x_25114' into 1.8_zy_3.10.x
2 parents 31df91a + 9957cfd commit c4a8144

File tree

2 files changed

+21
-4
lines changed

2 files changed

+21
-4
lines changed

hbase/hbase-side/hbase-side-core/src/main/java/com/dtstack/flink/sql/side/hbase/utils/HbaseUtils.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,12 @@ public static Object convertByte(byte[] hbaseData, String type){
6666

6767
case "double":
6868
return Bytes.toDouble(hbaseData);
69-
69+
case "decimal":
70+
return Bytes.toBigDecimal(hbaseData);
71+
default:
72+
throw new RuntimeException("not support type of " + type);
7073
}
71-
72-
throw new RuntimeException("not support type of " + type);
7374
}
75+
76+
7477
}

launcher/src/main/test/java/com/dtstack/flink/sql/launcher/PluginLoadModeTest.java

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,22 @@ public static void testClasspathMode() throws Exception {
4848
LauncherMain.main(sql);
4949
}
5050

51+
52+
public static void testRocSql() throws Exception{
53+
String[] sql = new String[]{"-mode", "local", "-sql", "/Users/roc/Documents/flink_sql/sql/zy_sql/hbase_side.sql", "-name", "roc",
54+
"-localSqlPluginPath", "/Users/roc/workspace/git_code/flinkStreamSQL/plugins",
55+
"-remoteSqlPluginPath", "/Users/roc/workspace/git_code/flinkStreamSQL/plugins",
56+
"-flinkconf", "/Users/roc/Documents/flink_sql/flinkconf",
57+
"-confProp", "{\"sql.checkpoint.cleanup.mode\":\"false\",\"sql.checkpoint.interval\":10000,\"time.characteristic\":\"EventTime\"}",
58+
"-yarnconf", "/Users/roc/Documents/flink_sql/yarnconf",
59+
"-flinkJarPath", "/Users/roc/Documents/flink_sql/flinkJarPath", "-queue", "c", "-pluginLoadMode", "classpath"};
60+
System.setProperty("HADOOP_USER_NAME", "admin");
61+
LauncherMain.main(sql);
62+
}
63+
5164
public static void main(String[] args) throws Exception {
52-
testShipfileMode();
65+
testRocSql();
66+
// testShipfileMode();
5367
// testClasspathMode();
5468
}
5569
}

0 commit comments

Comments
 (0)