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: iceberg.enabled in pulsar connector should be optional #13124

Merged
merged 1 commit into from
Oct 30, 2023
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/connector/src/source/pulsar/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ pub struct PulsarProperties {
pub common: PulsarCommon,

#[serde(rename = "iceberg.enabled")]
#[serde_as(as = "Option<DisplayFromStr>")]
pub iceberg_loader_enabled: bool,
#[serde_as(as = "DisplayFromStr")]
pub iceberg_loader_enabled: Option<bool>,

#[serde(rename = "iceberg.bucket", default)]
pub iceberg_bucket: Option<String>,
Expand Down
2 changes: 1 addition & 1 deletion src/connector/src/source/pulsar/source/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ impl SplitReader for PulsarSplitReader {

tracing::debug!("creating consumer for pulsar split topic {}", topic,);

if props.iceberg_loader_enabled
if props.iceberg_loader_enabled.unwrap_or(false)
&& matches!(split.start_offset, PulsarEnumeratorOffset::Earliest)
&& !topic.starts_with("non-persistent://")
{
Expand Down
Loading