Skip to content

Add reusable smoke test coverage for UPDATE#10355

Merged
findepi merged 1 commit intotrinodb:masterfrom
findepi:findepi/test-update
Jan 5, 2022
Merged

Add reusable smoke test coverage for UPDATE#10355
findepi merged 1 commit intotrinodb:masterfrom
findepi:findepi/test-update

Conversation

@findepi
Copy link
Copy Markdown
Member

@findepi findepi commented Dec 20, 2021

Currently no connector supports UPDATE in default configuration, but
this we should have the test for completeness.

In the future, we should have Hive full test run with transactional
tables being created by default. Also, Iceberg connector will support
UPDATE in its default configuration.

Currently no connector supports UPDATE in default configuration, but
this we should have the test for completeness.

In the future, we should have Hive full test run with transactional
tables being created by default. Also, Iceberg connector will support
UPDATE in its default configuration.
Copy link
Copy Markdown
Member

@hashhar hashhar left a comment

Choose a reason for hiding this comment

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

LGTM

{
if (!hasBehavior(SUPPORTS_UPDATE)) {
// Note this change is a no-op, if actually run
assertQueryFails("UPDATE nation SET nationkey = nationkey + regionkey WHERE regionkey < 1", "This connector does not support updates");
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can we in future omit such no-op operations in some connectors (hence silently breaking the test)?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I am not a big fan on testing that on a logically immutable table. If update has bug and actually mutates the table we will get weird test failures in a very unrelated place

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Can we in future omit such no-op operations in some connectors (hence silently breaking the test)?

@hashhar That would require implementing some form of UPDATE support.

If update has bug and actually mutates the table

@losipiuk in the worst case, the test env needs a fix. I don't think it's a big deal.

@findepi findepi merged commit 1bd30a9 into trinodb:master Jan 5, 2022
@findepi findepi deleted the findepi/test-update branch January 5, 2022 12:55
@github-actions github-actions bot added this to the 368 milestone Jan 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

5 participants