Skip to content

Rearrange SelectStatementContext constructor parameters#35497

Merged
terrymanu merged 2 commits intoapache:masterfrom
terrymanu:dev
May 23, 2025
Merged

Rearrange SelectStatementContext constructor parameters#35497
terrymanu merged 2 commits intoapache:masterfrom
terrymanu:dev

Conversation

@terrymanu
Copy link
Member

  • Reorder parameters to improve readability and consistency across usage
  • Update related test cases and classes to reflect the new constructor signature
  • Adjust subquery context creation to match the new parameter order

- Reorder parameters to improve readability and consistency across usage
- Update related test cases and classes to reflect the new constructor signature
- Adjust subquery context creation to match the new parameter order
@terrymanu terrymanu added this to the 5.5.3 milestone May 23, 2025
@terrymanu terrymanu requested a review from Copilot May 23, 2025 15:32
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR reorders the constructor parameters for SelectStatementContext to improve readability and consistency across different usages. The changes update all relevant call sites in both main and test code, ensuring that the new parameter order is consistently applied.

Reviewed Changes

Copilot reviewed 22 out of 22 changed files in this pull request and generated 1 comment.

File Description
infra/binder/core/src/main/java/org/apache/shardingsphere/infra/binder/context/statement/dml/SelectStatementContext.java Updated constructor parameter order and adjusted subquery context creation accordingly.
Other files (tests and DQL/DDL merger classes) Updated all instantiations of SelectStatementContext to match the new constructor signature.


public SelectStatementContext(final ShardingSphereMetaData metaData, final DatabaseType databaseType, final List<Object> params, final SelectStatement sqlStatement,
final String currentDatabaseName, final Collection<TableSegment> inheritedTables) {
public SelectStatementContext(final DatabaseType databaseType, final SelectStatement sqlStatement,
Copy link

Copilot AI May 23, 2025

Choose a reason for hiding this comment

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

Consider updating the constructor JavaDoc (or related documentation) to reflect the new parameter order for clarity.

Copilot uses AI. Check for mistakes.
- Reorder parameters to improve readability and consistency across usage
- Update related test cases and classes to reflect the new constructor signature
- Adjust subquery context creation to match the new parameter order
@terrymanu terrymanu merged commit ebd5c17 into apache:master May 23, 2025
18 checks passed
@terrymanu terrymanu deleted the dev branch May 23, 2025 15:38
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.

3 participants