Skip to content

Commit ea4a1b7

Browse files
committed
Support API GetPreSignedUrlForPutObject.
1 parent a2f9276 commit ea4a1b7

File tree

8 files changed

+304
-3
lines changed

8 files changed

+304
-3
lines changed

ververica-20220718/ChangeLog.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
2025-11-12 Version: 1.9.0
2+
- Support API GetPreSignedUrlForPutObject.
3+
4+
15
2025-10-21 Version: 1.8.0
26
- Support API CancelSqlPreview.
37
- Support API CreateDeploymentTargetV2.

ververica-20220718/pom.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<modelVersion>4.0.0</modelVersion>
44
<groupId>com.aliyun</groupId>
55
<artifactId>ververica20220718</artifactId>
6-
<version>1.8.0</version>
6+
<version>1.9.0</version>
77
<packaging>jar</packaging>
88
<name>ververica20220718</name>
99
<description>Alibaba Cloud ververica (20220718) SDK for Java
@@ -173,12 +173,11 @@
173173
<plugin>
174174
<groupId>org.sonatype.central</groupId>
175175
<artifactId>central-publishing-maven-plugin</artifactId>
176-
<version>0.8.0</version>
176+
<version>0.9.0</version>
177177
<extensions>true</extensions>
178178
<configuration>
179179
<publishingServerId>central</publishingServerId>
180180
<autoPublish>true</autoPublish>
181-
<waitUntil>published</waitUntil>
182181
</configuration>
183182
</plugin>
184183
</plugins>

ververica-20220718/src/main/java/com/aliyun/ververica20220718/Client.java

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2428,6 +2428,62 @@ public GetMemberResponse getMember(String namespace, String member) throws Excep
24282428
return this.getMemberWithOptions(namespace, member, headers, runtime);
24292429
}
24302430

2431+
/**
2432+
* <b>summary</b> :
2433+
* <p>获取上传文件URL</p>
2434+
*
2435+
* @param request GetPreSignedUrlForPutObjectRequest
2436+
* @param headers GetPreSignedUrlForPutObjectHeaders
2437+
* @param runtime runtime options for this request RuntimeOptions
2438+
* @return GetPreSignedUrlForPutObjectResponse
2439+
*/
2440+
public GetPreSignedUrlForPutObjectResponse getPreSignedUrlForPutObjectWithOptions(String namespace, GetPreSignedUrlForPutObjectRequest request, GetPreSignedUrlForPutObjectHeaders headers, com.aliyun.teautil.models.RuntimeOptions runtime) throws Exception {
2441+
com.aliyun.teautil.Common.validateModel(request);
2442+
java.util.Map<String, Object> query = new java.util.HashMap<>();
2443+
if (!com.aliyun.teautil.Common.isUnset(request.fileName)) {
2444+
query.put("fileName", request.fileName);
2445+
}
2446+
2447+
java.util.Map<String, String> realHeaders = new java.util.HashMap<>();
2448+
if (!com.aliyun.teautil.Common.isUnset(headers.commonHeaders)) {
2449+
realHeaders = headers.commonHeaders;
2450+
}
2451+
2452+
if (!com.aliyun.teautil.Common.isUnset(headers.workspace)) {
2453+
realHeaders.put("workspace", com.aliyun.teautil.Common.toJSONString(headers.workspace));
2454+
}
2455+
2456+
com.aliyun.teaopenapi.models.OpenApiRequest req = com.aliyun.teaopenapi.models.OpenApiRequest.build(TeaConverter.buildMap(
2457+
new TeaPair("headers", realHeaders),
2458+
new TeaPair("query", com.aliyun.openapiutil.Client.query(query))
2459+
));
2460+
com.aliyun.teaopenapi.models.Params params = com.aliyun.teaopenapi.models.Params.build(TeaConverter.buildMap(
2461+
new TeaPair("action", "GetPreSignedUrlForPutObject"),
2462+
new TeaPair("version", "2022-07-18"),
2463+
new TeaPair("protocol", "HTTPS"),
2464+
new TeaPair("pathname", "/artifacts/v2/namespaces/" + com.aliyun.openapiutil.Client.getEncodeParam(namespace) + "/getPreSignedUrlForPutObject"),
2465+
new TeaPair("method", "GET"),
2466+
new TeaPair("authType", "AK"),
2467+
new TeaPair("style", "ROA"),
2468+
new TeaPair("reqBodyType", "json"),
2469+
new TeaPair("bodyType", "json")
2470+
));
2471+
return TeaModel.toModel(this.callApi(params, req, runtime), new GetPreSignedUrlForPutObjectResponse());
2472+
}
2473+
2474+
/**
2475+
* <b>summary</b> :
2476+
* <p>获取上传文件URL</p>
2477+
*
2478+
* @param request GetPreSignedUrlForPutObjectRequest
2479+
* @return GetPreSignedUrlForPutObjectResponse
2480+
*/
2481+
public GetPreSignedUrlForPutObjectResponse getPreSignedUrlForPutObject(String namespace, GetPreSignedUrlForPutObjectRequest request) throws Exception {
2482+
com.aliyun.teautil.models.RuntimeOptions runtime = new com.aliyun.teautil.models.RuntimeOptions();
2483+
GetPreSignedUrlForPutObjectHeaders headers = new GetPreSignedUrlForPutObjectHeaders();
2484+
return this.getPreSignedUrlForPutObjectWithOptions(namespace, request, headers, runtime);
2485+
}
2486+
24312487
/**
24322488
* <b>summary</b> :
24332489
* <p>Queries details of a savepoint and checkpoint.</p>
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
// This file is auto-generated, don't edit it. Thanks.
2+
package com.aliyun.ververica20220718.models;
3+
4+
import com.aliyun.tea.*;
5+
6+
public class GetPreSignedUrlForObjectResult extends TeaModel {
7+
@NameInMap("jarUrl")
8+
public String jarUrl;
9+
10+
@NameInMap("preSignedUrl")
11+
public String preSignedUrl;
12+
13+
public static GetPreSignedUrlForObjectResult build(java.util.Map<String, ?> map) throws Exception {
14+
GetPreSignedUrlForObjectResult self = new GetPreSignedUrlForObjectResult();
15+
return TeaModel.build(map, self);
16+
}
17+
18+
public GetPreSignedUrlForObjectResult setJarUrl(String jarUrl) {
19+
this.jarUrl = jarUrl;
20+
return this;
21+
}
22+
public String getJarUrl() {
23+
return this.jarUrl;
24+
}
25+
26+
public GetPreSignedUrlForObjectResult setPreSignedUrl(String preSignedUrl) {
27+
this.preSignedUrl = preSignedUrl;
28+
return this;
29+
}
30+
public String getPreSignedUrl() {
31+
return this.preSignedUrl;
32+
}
33+
34+
}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
// This file is auto-generated, don't edit it. Thanks.
2+
package com.aliyun.ververica20220718.models;
3+
4+
import com.aliyun.tea.*;
5+
6+
public class GetPreSignedUrlForPutObjectHeaders extends TeaModel {
7+
@NameInMap("commonHeaders")
8+
public java.util.Map<String, String> commonHeaders;
9+
10+
/**
11+
* <p>This parameter is required.</p>
12+
*
13+
* <strong>example:</strong>
14+
* <p>a9c3a20210af000</p>
15+
*/
16+
@NameInMap("workspace")
17+
public String workspace;
18+
19+
public static GetPreSignedUrlForPutObjectHeaders build(java.util.Map<String, ?> map) throws Exception {
20+
GetPreSignedUrlForPutObjectHeaders self = new GetPreSignedUrlForPutObjectHeaders();
21+
return TeaModel.build(map, self);
22+
}
23+
24+
public GetPreSignedUrlForPutObjectHeaders setCommonHeaders(java.util.Map<String, String> commonHeaders) {
25+
this.commonHeaders = commonHeaders;
26+
return this;
27+
}
28+
public java.util.Map<String, String> getCommonHeaders() {
29+
return this.commonHeaders;
30+
}
31+
32+
public GetPreSignedUrlForPutObjectHeaders setWorkspace(String workspace) {
33+
this.workspace = workspace;
34+
return this;
35+
}
36+
public String getWorkspace() {
37+
return this.workspace;
38+
}
39+
40+
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
// This file is auto-generated, don't edit it. Thanks.
2+
package com.aliyun.ververica20220718.models;
3+
4+
import com.aliyun.tea.*;
5+
6+
public class GetPreSignedUrlForPutObjectRequest extends TeaModel {
7+
/**
8+
* <p>This parameter is required.</p>
9+
*
10+
* <strong>example:</strong>
11+
* <p>example.txt</p>
12+
*/
13+
@NameInMap("fileName")
14+
public String fileName;
15+
16+
public static GetPreSignedUrlForPutObjectRequest build(java.util.Map<String, ?> map) throws Exception {
17+
GetPreSignedUrlForPutObjectRequest self = new GetPreSignedUrlForPutObjectRequest();
18+
return TeaModel.build(map, self);
19+
}
20+
21+
public GetPreSignedUrlForPutObjectRequest setFileName(String fileName) {
22+
this.fileName = fileName;
23+
return this;
24+
}
25+
public String getFileName() {
26+
return this.fileName;
27+
}
28+
29+
}
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
// This file is auto-generated, don't edit it. Thanks.
2+
package com.aliyun.ververica20220718.models;
3+
4+
import com.aliyun.tea.*;
5+
6+
public class GetPreSignedUrlForPutObjectResponse extends TeaModel {
7+
@NameInMap("headers")
8+
public java.util.Map<String, String> headers;
9+
10+
@NameInMap("statusCode")
11+
public Integer statusCode;
12+
13+
@NameInMap("body")
14+
public GetPreSignedUrlForPutObjectResponseBody body;
15+
16+
public static GetPreSignedUrlForPutObjectResponse build(java.util.Map<String, ?> map) throws Exception {
17+
GetPreSignedUrlForPutObjectResponse self = new GetPreSignedUrlForPutObjectResponse();
18+
return TeaModel.build(map, self);
19+
}
20+
21+
public GetPreSignedUrlForPutObjectResponse setHeaders(java.util.Map<String, String> headers) {
22+
this.headers = headers;
23+
return this;
24+
}
25+
public java.util.Map<String, String> getHeaders() {
26+
return this.headers;
27+
}
28+
29+
public GetPreSignedUrlForPutObjectResponse setStatusCode(Integer statusCode) {
30+
this.statusCode = statusCode;
31+
return this;
32+
}
33+
public Integer getStatusCode() {
34+
return this.statusCode;
35+
}
36+
37+
public GetPreSignedUrlForPutObjectResponse setBody(GetPreSignedUrlForPutObjectResponseBody body) {
38+
this.body = body;
39+
return this;
40+
}
41+
public GetPreSignedUrlForPutObjectResponseBody getBody() {
42+
return this.body;
43+
}
44+
45+
}
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
// This file is auto-generated, don't edit it. Thanks.
2+
package com.aliyun.ververica20220718.models;
3+
4+
import com.aliyun.tea.*;
5+
6+
public class GetPreSignedUrlForPutObjectResponseBody extends TeaModel {
7+
@NameInMap("data")
8+
public GetPreSignedUrlForObjectResult data;
9+
10+
/**
11+
* <strong>example:</strong>
12+
* <p>990301</p>
13+
*/
14+
@NameInMap("errorCode")
15+
public String errorCode;
16+
17+
/**
18+
* <strong>example:</strong>
19+
* <p>文件不存在</p>
20+
*/
21+
@NameInMap("errorMessage")
22+
public String errorMessage;
23+
24+
/**
25+
* <strong>example:</strong>
26+
* <p>200</p>
27+
*/
28+
@NameInMap("httpCode")
29+
public Integer httpCode;
30+
31+
/**
32+
* <strong>example:</strong>
33+
* <p>1234567890</p>
34+
*/
35+
@NameInMap("requestId")
36+
public String requestId;
37+
38+
@NameInMap("success")
39+
public Boolean success;
40+
41+
public static GetPreSignedUrlForPutObjectResponseBody build(java.util.Map<String, ?> map) throws Exception {
42+
GetPreSignedUrlForPutObjectResponseBody self = new GetPreSignedUrlForPutObjectResponseBody();
43+
return TeaModel.build(map, self);
44+
}
45+
46+
public GetPreSignedUrlForPutObjectResponseBody setData(GetPreSignedUrlForObjectResult data) {
47+
this.data = data;
48+
return this;
49+
}
50+
public GetPreSignedUrlForObjectResult getData() {
51+
return this.data;
52+
}
53+
54+
public GetPreSignedUrlForPutObjectResponseBody setErrorCode(String errorCode) {
55+
this.errorCode = errorCode;
56+
return this;
57+
}
58+
public String getErrorCode() {
59+
return this.errorCode;
60+
}
61+
62+
public GetPreSignedUrlForPutObjectResponseBody setErrorMessage(String errorMessage) {
63+
this.errorMessage = errorMessage;
64+
return this;
65+
}
66+
public String getErrorMessage() {
67+
return this.errorMessage;
68+
}
69+
70+
public GetPreSignedUrlForPutObjectResponseBody setHttpCode(Integer httpCode) {
71+
this.httpCode = httpCode;
72+
return this;
73+
}
74+
public Integer getHttpCode() {
75+
return this.httpCode;
76+
}
77+
78+
public GetPreSignedUrlForPutObjectResponseBody setRequestId(String requestId) {
79+
this.requestId = requestId;
80+
return this;
81+
}
82+
public String getRequestId() {
83+
return this.requestId;
84+
}
85+
86+
public GetPreSignedUrlForPutObjectResponseBody setSuccess(Boolean success) {
87+
this.success = success;
88+
return this;
89+
}
90+
public Boolean getSuccess() {
91+
return this.success;
92+
}
93+
94+
}

0 commit comments

Comments
 (0)