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

fix: temp disable option check on source options #13362

Merged
merged 2 commits into from
Nov 10, 2023

Conversation

tabVersion
Copy link
Contributor

@tabVersion tabVersion commented Nov 10, 2023

I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.

What's changed and what's your intention?

the check will block a normal query be like

create source ( ... )
format plain encode protobuf (
  message = 'xxx',
  schema.registry.url = 'xxx',
  schema.registry.username = 'foo',
  schema.registry.password = 'bar'
);

it will output

ERROR:  QueryError: Protocol error: Unknown options for Plain Protobuf: schema.registry.password:bar,schema.registry.username:foo

because these options are consumed from a copy of the props

extract_protobuf_table_schema(&protobuf_schema, with_properties.clone())

Checklist

  • I have written necessary rustdoc comments
  • I have added necessary unit tests and integration tests
  • I have added fuzzing tests or opened an issue to track them. (Optional, recommended for new SQL features Sqlsmith: Sql feature generation #7934).
  • My PR contains breaking changes. (If it deprecates some features, please create a tracking issue to remove them in the future).
  • All checks passed in ./risedev check (or alias, ./risedev c)
  • My PR changes performance-critical code. (Please run macro/micro-benchmarks and show the results.)
  • My PR contains critical fixes that are necessary to be merged into the latest release. (Please check out the details)

Documentation

  • My PR needs documentation updates. (Please use the Release note section below to summarize the impact on users)

Release note

If this PR includes changes that directly affect users or other significant modifications relevant to the community, kindly draft a release note to provide a concise summary of these changes. Please prioritize highlighting the impact these changes will have on users.

Copy link

codecov bot commented Nov 10, 2023

Codecov Report

Merging #13362 (c01a1c7) into main (b8b812d) will increase coverage by 0.06%.
Report is 12 commits behind head on main.
The diff coverage is 66.66%.

@@            Coverage Diff             @@
##             main   #13362      +/-   ##
==========================================
+ Coverage   67.74%   67.81%   +0.06%     
==========================================
  Files        1524     1524              
  Lines      259436   259443       +7     
==========================================
+ Hits       175766   175941     +175     
+ Misses      83670    83502     -168     
Flag Coverage Δ
rust 67.81% <66.66%> (+0.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/connector/src/schema/schema_registry/client.rs 0.65% <ø> (+0.02%) ⬆️
src/frontend/src/handler/create_table.rs 71.39% <100.00%> (ø)
src/frontend/src/handler/create_source.rs 56.82% <65.00%> (+0.34%) ⬆️

... and 21 files with indirect coverage changes

📣 Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today!

@StrikeW
Copy link
Contributor

StrikeW commented Nov 10, 2023

Would you mind create a issue to track this problem?

@tabVersion
Copy link
Contributor Author

Would you mind create a issue to track this problem?

sure, #13365

@yuhao-su
Copy link
Contributor

with_properties is only used as a immutable reference in the function event it was cloned. And the problem is about the option instead of the prop?

@tabVersion
Copy link
Contributor Author

merge for online fix, lets have offline discussions later

@tabVersion tabVersion added this pull request to the merge queue Nov 10, 2023
@yuhao-su
Copy link
Contributor

with_properties contains password and username for the connector, and we are also using those properties for the schema registry...

We should use password and username in options, which is actually the properties of ENCODE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/fix Bug fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants