Skip to content

Conversation

@gruuya
Copy link
Contributor

@gruuya gruuya commented Aug 6, 2024

This is to signal a transaction end.

Also rename batch compaction to squashing throughout.

@gruuya gruuya requested review from eatonphil and mildbyte August 6, 2024 07:56
})?
} else {
None
SyncSchema::empty()
Copy link
Contributor

Choose a reason for hiding this comment

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

Can this actually legitimately happen now or should we always expect that there is a schema?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It seems that providing an empty payload (vec![]) is easier than providing a non-empty payload with empty record batches (vec![RecordBatch::new_empty(schema)]), so I think yes.

Let's hear from @eatonphil though.

Copy link
Collaborator

Choose a reason for hiding this comment

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

It seems that providing an empty payload (vec![]) is easier than providing a non-empty payload with empty record batches (vec![RecordBatch::new_empty(schema)]), so I think yes.

Well, let me try. I have such a hard time with the Arrow APIs I was scared to try. But if you think that's better I'll give it a shot.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It may still better of to have special casing of the empty payload, than to rely on the rest of the mechanism to adequately process those messages (so this change is for the better anyway).

Copy link
Collaborator

Choose a reason for hiding this comment

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

Alright, let's go with it then.

@gruuya gruuya merged commit 5b0462f into main Aug 6, 2024
@gruuya gruuya deleted the support-empty-sync branch August 6, 2024 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants