Skip to content

Commit 4608762

Browse files
hybolldybyte
authored andcommitted
[Bug] [Connector-V2] Fix the issue of writing the ORC format Iceberg report "Illegal provider-class name" (apache#6754) (apache#9588)
1 parent f2adaa1 commit 4608762

File tree

3 files changed

+83
-1
lines changed

3 files changed

+83
-1
lines changed

seatunnel-connectors-v2/connector-iceberg/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<parquet-avro.version>1.13.1</parquet-avro.version>
3535
<avro.version>1.11.3</avro.version>
3636
<hive.version>2.3.9</hive.version>
37-
<connector.name>connector-iceberg</connector.name>
37+
<connector.name>connector.iceberg</connector.name>
3838
<software.amazon.awssdk.version>2.31.30</software.amazon.awssdk.version>
3939
</properties>
4040

seatunnel-e2e/seatunnel-connector-v2-e2e/connector-iceberg-e2e/src/test/java/org/apache/seatunnel/e2e/connector/iceberg/IcebergSinkIT.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,14 @@ public void testInsertAndCheckDataE2e(TestContainer container)
139139
});
140140
}
141141

142+
@TestTemplate
143+
public void testORCFileFormatWrite(TestContainer container)
144+
throws IOException, InterruptedException {
145+
Container.ExecResult textWriteResult =
146+
container.executeJob("/iceberg/fake_to_orc_iceberg.conf");
147+
Assertions.assertEquals(0, textWriteResult.getExitCode());
148+
}
149+
142150
private List<Record> loadIcebergTable() {
143151
List<Record> results = new ArrayList<>();
144152
Map<String, Object> configs = new HashMap<>();
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
#
2+
# Licensed to the Apache Software Foundation (ASF) under one or more
3+
# contributor license agreements. See the NOTICE file distributed with
4+
# this work for additional information regarding copyright ownership.
5+
# The ASF licenses this file to You under the Apache License, Version 2.0
6+
# (the "License"); you may not use this file except in compliance with
7+
# the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
#
17+
18+
env {
19+
parallelism = 1
20+
job.mode = "BATCH"
21+
22+
# You can set spark configuration here
23+
spark.app.name = "SeaTunnel"
24+
spark.executor.instances = 2
25+
spark.executor.cores = 1
26+
spark.executor.memory = "1g"
27+
spark.master = local
28+
}
29+
30+
source {
31+
FakeSource {
32+
row.num = 100
33+
schema = {
34+
fields {
35+
c_map = "map<string, string>"
36+
c_array = "array<int>"
37+
c_string = string
38+
c_boolean = boolean
39+
c_tinyint = tinyint
40+
c_smallint = smallint
41+
c_int = int
42+
c_bigint = bigint
43+
c_float = float
44+
c_double = double
45+
c_decimal = "decimal(30, 8)"
46+
c_bytes = bytes
47+
c_date = date
48+
c_timestamp = timestamp
49+
}
50+
}
51+
plugin_output = "fake"
52+
}
53+
}
54+
55+
transform {
56+
}
57+
58+
sink {
59+
Iceberg {
60+
catalog_name="seatunnel_test"
61+
iceberg.catalog.config={
62+
"type"="hadoop"
63+
"warehouse"="file:///tmp/seatunnel/iceberg/hadoop-sink/"
64+
}
65+
namespace="seatunnel_namespace"
66+
table="iceberg_sink_table"
67+
iceberg.table.write-props={
68+
write.format.default="orc"
69+
write.target-file-size-bytes=10
70+
}
71+
iceberg.table.partition-keys="c_timestamp"
72+
case_sensitive=true
73+
}
74+
}

0 commit comments

Comments
 (0)