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

Remove deprecated API from ConnectorPageSourceProvider #1095

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -26,19 +26,6 @@ default ConnectorPageSource createPageSource(
ConnectorSplit split,
Copy link
Member

Choose a reason for hiding this comment

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

a typo in commit msg and PR title

ConnectorTableHandle table,
List<ColumnHandle> columns)
{
return createPageSource(transaction, session, split, columns);
}

/**
* @param columns columns that should show up in the output page, in this order
*/
@Deprecated
Copy link
Member

Choose a reason for hiding this comment

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

when it was deprecated?

Copy link
Member Author

Choose a reason for hiding this comment

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

IIRC we had one issue where TupleDomain was common for a table scan and we are copying it for all splits so we capture it in TableHandle and pass it to the worker so the size of split can be reduced

Copy link
Member

Choose a reason for hiding this comment

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

default ConnectorPageSource createPageSource(
ConnectorTransactionHandle transactionHandle,
ConnectorSession session,
ConnectorSplit split,
List<ColumnHandle> columns)
{
throw new UnsupportedOperationException("createPageSource() must be implemented");
}
Expand Down
Expand Up @@ -38,14 +38,6 @@ public ClassLoaderSafeConnectorPageSourceProvider(ConnectorPageSourceProvider de
this.classLoader = requireNonNull(classLoader, "classLoader is null");
}

@Override
public ConnectorPageSource createPageSource(ConnectorTransactionHandle transactionHandle, ConnectorSession session, ConnectorSplit split, List<ColumnHandle> columns)
{
try (ThreadContextClassLoader ignored = new ThreadContextClassLoader(classLoader)) {
return delegate.createPageSource(transactionHandle, session, split, columns);
}
}

@Override
public ConnectorPageSource createPageSource(ConnectorTransactionHandle transaction, ConnectorSession session, ConnectorSplit split, ConnectorTableHandle table, List<ColumnHandle> columns)
{
Expand Down