Skip to content

Commit 2054c63

Browse files
authored
repo-sync-2025-02-18T20:16:02+0800 (#19)
* repo-sync-2025-02-18T20:16:02+0800 * restore: git restore --source=HEAD~1 * restore: cherry-pick sdk modify
1 parent d30da95 commit 2054c63

File tree

72 files changed

+809
-1980
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+809
-1980
lines changed

.licenserc.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ header: # <1>
7070
- 'pyproject.toml'
7171
- 'setup.cfg'
7272
- 'dataproxy-manager/src/main/java/org/secretflow/dataproxy/manager/connector/rdbms/adaptor'
73+
- '**/src/main/resources/META-INF/services/**'
7374

7475
comment: never # <9>
7576

build/Dockerfiles/dataproxy.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
FROM secretflow-registry.cn-hangzhou.cr.aliyuncs.com/secretflow/secretpad-base-lite:0.3
15+
FROM secretflow-registry.cn-hangzhou.cr.aliyuncs.com/secretflow/java-base:17.0.13-jre-anolis23
1616

1717
ENV LANG=C.UTF-8
1818
WORKDIR /app

dataproxy-api/pom.xml

+47-7
Original file line numberDiff line numberDiff line change
@@ -16,25 +16,65 @@
1616
<dependency>
1717
<groupId>com.google.protobuf</groupId>
1818
<artifactId>protobuf-java</artifactId>
19-
</dependency>
20-
<dependency>
21-
<groupId>com.google.protobuf</groupId>
22-
<artifactId>protobuf-java-util</artifactId>
19+
<optional>true</optional>
2320
</dependency>
2421
<dependency>
2522
<groupId>io.grpc</groupId>
2623
<artifactId>grpc-protobuf</artifactId>
27-
<scope>compile</scope>
24+
<exclusions>
25+
<exclusion>
26+
<groupId>io.grpc</groupId>
27+
<artifactId>grpc-protobuf-lite</artifactId>
28+
</exclusion>
29+
<exclusion>
30+
<groupId>com.google.api.grpc</groupId>
31+
<artifactId>proto-google-common-protos</artifactId>
32+
</exclusion>
33+
<exclusion>
34+
<groupId>com.google.errorprone</groupId>
35+
<artifactId>error_prone_annotations</artifactId>
36+
</exclusion>
37+
<exclusion>
38+
<groupId>com.google.code.findbugs</groupId>
39+
<artifactId>findbugs</artifactId>
40+
</exclusion>
41+
<exclusion>
42+
<groupId>com.google.guava</groupId>
43+
<artifactId>listenablefuture</artifactId>
44+
</exclusion>
45+
<exclusion>
46+
<groupId>com.google.code.findbugs</groupId>
47+
<artifactId>jsr305</artifactId>
48+
</exclusion>
49+
<exclusion>
50+
<groupId>com.google.guava</groupId>
51+
<artifactId>failureaccess</artifactId>
52+
</exclusion>
53+
<exclusion>
54+
<groupId>org.checkerframework</groupId>
55+
<artifactId>checker-qual</artifactId>
56+
</exclusion>
57+
<exclusion>
58+
<groupId>com.google.j2objc</groupId>
59+
<artifactId>j2objc-annotations</artifactId>
60+
</exclusion>
61+
</exclusions>
2862
</dependency>
2963
<dependency>
3064
<groupId>io.grpc</groupId>
3165
<artifactId>grpc-stub</artifactId>
32-
<scope>compile</scope>
66+
<exclusions>
67+
<exclusion>
68+
<groupId>com.google.errorprone</groupId>
69+
<artifactId>error_prone_annotations</artifactId>
70+
</exclusion>
71+
</exclusions>
72+
<optional>true</optional>
3373
</dependency>
3474
<dependency>
3575
<groupId>javax.annotation</groupId>
3676
<artifactId>javax.annotation-api</artifactId>
37-
<scope>compile</scope>
77+
<optional>true</optional>
3878
</dependency>
3979
</dependencies>
4080

dataproxy-common/pom.xml

+93-63
Original file line numberDiff line numberDiff line change
@@ -13,86 +13,116 @@
1313
<artifactId>dataproxy-common</artifactId>
1414

1515
<dependencies>
16-
<dependency>
17-
<groupId>org.secretflow</groupId>
18-
<artifactId>dataproxy-api</artifactId>
19-
</dependency>
2016

2117
<dependency>
2218
<groupId>org.projectlombok</groupId>
2319
<artifactId>lombok</artifactId>
24-
<scope>compile</scope>
25-
</dependency>
26-
<!--<dependency>
27-
<groupId>com.fasterxml.jackson.datatype</groupId>
28-
<artifactId>jackson-datatype-jsr310</artifactId>
29-
</dependency>-->
30-
<!--<dependency>
31-
<groupId>org.apache.commons</groupId>
32-
<artifactId>commons-collections4</artifactId>
33-
</dependency>-->
34-
<!--<dependency>
35-
<groupId>org.apache.commons</groupId>
36-
<artifactId>commons-lang3</artifactId>
37-
</dependency>
38-
<dependency>
39-
<groupId>commons-io</groupId>
40-
<artifactId>commons-io</artifactId>
41-
</dependency>-->
42-
<dependency>
43-
<groupId>io.netty</groupId>
44-
<artifactId>netty-all</artifactId>
45-
</dependency>
46-
<dependency>
47-
<groupId>io.netty</groupId>
48-
<artifactId>netty-tcnative-boringssl-static</artifactId>
49-
</dependency>
50-
<!--<dependency>
51-
<groupId>com.squareup.okio</groupId>
52-
<artifactId>okio</artifactId>
53-
</dependency>-->
54-
55-
<dependency>
56-
<groupId>com.google.protobuf</groupId>
57-
<artifactId>protobuf-java-util</artifactId>
58-
</dependency>
59-
60-
<!-- apache arrow start-->
61-
<dependency>
62-
<groupId>org.apache.arrow</groupId>
63-
<artifactId>arrow-vector</artifactId>
64-
</dependency>
65-
66-
<dependency>
67-
<groupId>org.apache.arrow</groupId>
68-
<artifactId>arrow-dataset</artifactId>
6920
</dependency>
7021

7122
<dependency>
72-
<groupId>org.apache.arrow</groupId>
73-
<artifactId>arrow-memory-netty</artifactId>
23+
<groupId>org.slf4j</groupId>
24+
<artifactId>slf4j-api</artifactId>
25+
<optional>true</optional>
7426
</dependency>
7527

7628
<dependency>
77-
<groupId>org.apache.arrow</groupId>
78-
<artifactId>arrow-format</artifactId>
29+
<groupId>com.fasterxml.jackson.datatype</groupId>
30+
<artifactId>jackson-datatype-jsr310</artifactId>
7931
</dependency>
8032

8133
<dependency>
8234
<groupId>org.apache.arrow</groupId>
8335
<artifactId>flight-core</artifactId>
84-
</dependency>
85-
<!--<dependency>
86-
<groupId>org.apache.arrow</groupId>
87-
<artifactId>flight-grpc</artifactId>
88-
</dependency>-->
36+
<exclusions>
37+
<exclusion>
38+
<groupId>org.apache.arrow</groupId>
39+
<artifactId>arrow-format</artifactId>
40+
</exclusion>
41+
<exclusion>
42+
<groupId>org.apache.arrow</groupId>
43+
<artifactId>arrow-memory-core</artifactId>
44+
</exclusion>
45+
<exclusion>
46+
<groupId>org.apache.arrow</groupId>
47+
<artifactId>arrow-memory</artifactId>
48+
</exclusion>
49+
<exclusion>
50+
<groupId>org.apache.arrow</groupId>
51+
<artifactId>arrow-memory-netty</artifactId>
52+
</exclusion>
53+
<exclusion>
54+
<groupId>io.netty</groupId>
55+
<artifactId>netty-all</artifactId>
56+
</exclusion>
57+
<exclusion>
58+
<groupId>io.netty</groupId>
59+
<artifactId>netty-buffer</artifactId>
60+
</exclusion>
61+
<exclusion>
62+
<groupId>io.netty</groupId>
63+
<artifactId>netty-handler</artifactId>
64+
</exclusion>
65+
<exclusion>
66+
<groupId>io.netty</groupId>
67+
<artifactId>netty-transport</artifactId>
68+
</exclusion>
69+
<exclusion>
70+
<groupId>io.netty</groupId>
71+
<artifactId>netty-tcnative-boringssl-static</artifactId>
72+
</exclusion>
8973

90-
<!-- apache arrow end-->
74+
<exclusion>
75+
<groupId>io.grpc</groupId>
76+
<artifactId>grpc-api</artifactId>
77+
</exclusion>
78+
<exclusion>
79+
<groupId>io.grpc</groupId>
80+
<artifactId>grpc-protobuf</artifactId>
81+
</exclusion>
82+
<exclusion>
83+
<groupId>io.grpc</groupId>
84+
<artifactId>grpc-protobuf-lite</artifactId>
85+
</exclusion>
86+
<exclusion>
87+
<groupId>io.grpc</groupId>
88+
<artifactId>grpc-netty</artifactId>
89+
</exclusion>
90+
<exclusion>
91+
<groupId>io.grpc</groupId>
92+
<artifactId>grpc-context</artifactId>
93+
</exclusion>
94+
<exclusion>
95+
<groupId>io.grpc</groupId>
96+
<artifactId>grpc-core</artifactId>
97+
</exclusion>
98+
<exclusion>
99+
<groupId>io.grpc</groupId>
100+
<artifactId>grpc-stub</artifactId>
101+
</exclusion>
102+
<exclusion>
103+
<groupId>com.google.protobuf</groupId>
104+
<artifactId>protobuf-java-util</artifactId>
105+
</exclusion>
106+
<exclusion>
107+
<groupId>com.google.guava</groupId>
108+
<artifactId>guava</artifactId>
109+
</exclusion>
110+
<exclusion>
111+
<groupId>javax.annotation</groupId>
112+
<artifactId>javax.annotation-api</artifactId>
113+
</exclusion>
114+
<exclusion>
115+
<groupId>commons-codec</groupId>
116+
<artifactId>commons-codec</artifactId>
117+
</exclusion>
118+
<exclusion>
119+
<groupId>com.google.flatbuffers</groupId>
120+
<artifactId>flatbuffers-java</artifactId>
121+
</exclusion>
122+
</exclusions>
123+
<optional>true</optional>
124+
</dependency>
91125

92-
<!--<dependency>
93-
<groupId>javax.annotation</groupId>
94-
<artifactId>javax.annotation-api</artifactId>
95-
</dependency>-->
96126
</dependencies>
97127

98128
</project>

dataproxy-common/src/main/java/org/secretflow/dataproxy/common/exceptions/DataproxyErrorCode.java

+2
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ public enum DataproxyErrorCode {
9292
ODPS_PARTITION_NOT_EXISTS(ErrorLevels.ERROR, ErrorTypes.BIZ, "606", "odps partition not exists"),
9393
ODPS_TABLE_NOT_EMPTY(ErrorLevels.ERROR, ErrorTypes.BIZ, "607", "odps table not empty"),
9494
ODPS_TABLE_NOT_SUPPORT_PARTITION(ErrorLevels.ERROR, ErrorTypes.BIZ, "608", "odps table not support partition"),
95+
ODPS_TASK_NOT_READY(ErrorLevels.ERROR, ErrorTypes.BIZ, "609", "odps task not ready"),
96+
ODPS_TASK_NOT_RUN(ErrorLevels.ERROR, ErrorTypes.BIZ, "610", "odps task not run"),
9597

9698

9799
//============================= 第三方错误【900-999】==================================

dataproxy-common/src/main/java/org/secretflow/dataproxy/common/exceptions/DataproxyException.java

+8-4
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,24 @@
1616

1717
package org.secretflow.dataproxy.common.exceptions;
1818

19+
import lombok.Getter;
1920
import lombok.extern.slf4j.Slf4j;
2021

22+
import java.io.Serial;
23+
2124
/**
2225
* dataproxy exception
2326
*
2427
* @author muhong
2528
* @date 2023-09-14 14:23
2629
*/
30+
@Getter
2731
@Slf4j
2832
public class DataproxyException extends RuntimeException {
33+
34+
@Serial
35+
private static final long serialVersionUID = -9012364334166955517L;
36+
2937
private final DataproxyErrorCode errorCode;
3038

3139
public DataproxyException(DataproxyErrorCode errorCode) {
@@ -64,10 +72,6 @@ public static DataproxyException of(DataproxyErrorCode errorCode, String message
6472
return new DataproxyException(errorCode, message, cause);
6573
}
6674

67-
public DataproxyErrorCode getErrorCode() {
68-
return errorCode;
69-
}
70-
7175
public String getDescription() {
7276
return String.format("code: %s, message: %s", getErrorCode().getErrorCode(), getMessage());
7377
}

dataproxy-common/src/main/java/org/secretflow/dataproxy/common/model/FlightContentFormatConfig.java

-45
This file was deleted.

dataproxy-common/src/main/java/org/secretflow/dataproxy/common/model/FlightContentFormatTypeEnum.java

-32
This file was deleted.

0 commit comments

Comments
 (0)