Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature][Connector-V2] Support TableSourceFactory/TableSinkFactory on http #5816

Merged
merged 16 commits into from
Nov 22, 2023

Conversation

jackyyyyyssss
Copy link
Contributor

@jackyyyyyssss jackyyyyyssss commented Nov 8, 2023

Purpose of this pull request

#5807 #5651 [Feature][Connector-V2] Support TableSourceFactory/TableSinkFactory on http

Does this PR introduce any user-facing change?

How was this patch tested?

improve current e2e test

Check list

@jackyyyyyssss jackyyyyyssss changed the title [Feature][Connector-V2] Support TableSourceFactory/TableSinkFactory on http #5807 [Feature][Connector-V2] Support TableSourceFactory/TableSinkFactory on http Nov 8, 2023
Copy link
Member

@Hisoka-X Hisoka-X left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jackyyyyyssss
Copy link
Contributor Author

Please change getProducedType to getProducedCatalogTables in HttpSource. https://github.com/apache/seatunnel/pull/5816/files#diff-7c704c6a3927123b31b41483102f286339da3832309810496f19410c2548f06fR153

done PTAL

public void setTypeInfo(SeaTunnelRowType seaTunnelRowType) {
this.seaTunnelRowType = seaTunnelRowType;
public String getPluginName() {
return "Http";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can use CONNECTOR_IDENTITY to replace Http now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -49,7 +61,6 @@ public OptionRule.Builder getHttpBuilder() {
.optional(HttpConfig.FORMAT)
.optional(HttpConfig.JSON_FIELD)
.optional(HttpConfig.CONTENT_FIELD)
.conditional(HttpConfig.METHOD, HttpRequestMethod.POST, HttpConfig.BODY)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why remove this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because when using the params parameter, the post method is also used without a body

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, And you need add HttpConfig.BODY use .optional(HttpConfig.BODY). Otherwise, the body parameter will be lost.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done PTAL @EricJoy2048

Copy link
Member

@Hisoka-X Hisoka-X left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @jackyyyyyssss !

@Hisoka-X Hisoka-X merged commit 6f49ec6 into apache:dev Nov 22, 2023
5 checks passed
alextinng pushed a commit to alextinng/seatunnel that referenced this pull request Dec 19, 2023
…n http (apache#5816)



---------

Co-authored-by: 80597928 <673421862@qq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants