-
Notifications
You must be signed in to change notification settings - Fork 13.9k
[FLINK-11451][table] move *QueryConfig and TableDescriptor to flink-table-api-java #7621
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
Conversation
dawidwys
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @xueyumusic , thank you for the contribution.
I put some comments. Also could you please move the TableDescriptor to table-common module, as answered in JIRA?
| * The {@link QueryConfig} holds parameters to configure the behavior of queries. | ||
| */ | ||
| @PublicEvolving | ||
| public class QueryConfig implements Serializable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be an interface.
| /** | ||
| * The {@link BatchQueryConfig} holds parameters to configure the behavior of batch queries. | ||
| */ | ||
| @PublicEvolving |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn't add this annotation. This class will actually be dropped in a near future, once we have one unified TableEnvironment.
| * <p>An empty {@link StreamQueryConfig} can be generated using the [[StreamTableEnvironment.queryConfig]] | ||
| * method. | ||
| */ | ||
| @PublicEvolving |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as for BatchQueryConfig. Let's not add this annotation.
| /** | ||
| * The {@link StreamQueryConfig} holds parameters to configure the behavior of streaming queries. | ||
| * | ||
| * <p>An empty {@link StreamQueryConfig} can be generated using the [[StreamTableEnvironment.queryConfig]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please convert [[StreamTableEnvironment.queryConfig]] as well.
| return this; | ||
| } | ||
|
|
||
| public long getMinIdleStateRetentionTime() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add javadoc for those methods? I think we can reuse the description for corresponding field.
| */ | ||
| abstract class TableDescriptor extends DescriptorBase | ||
| @PublicEvolving | ||
| public abstract class TableDescriptor extends DescriptorBase { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a thought. How about we convert it to interface? That means converting DescriptorBase to interface as well. What do you think @twalthr about it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, @dawidwys , thanks for review. I updated the code except this place right now.
It looks DescriptorBase overrides toString() method implementation, if it is converted to interface how to migrate this method...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, wasn't aware you cannot override methods from Object with defaultmethods. Forget about this comment then.
|
Thank you @xueyumusic for your contribution |
What is the purpose of the change
This PR moves QueryConfig, BatchQueryConfig, StreamQueryConfig and TableDescriptor to flink-table-api-java
Brief change log
Verifying this change
This change is already covered by existing tests, such as (please describe tests).
Does this pull request potentially affect one of the following parts:
@Public(Evolving): (yes)Documentation