Skip to content

enhancement: add stream type to stream definition #884

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

Merged
merged 3 commits into from
Aug 13, 2024

Conversation

nikhilsinhaparseable
Copy link
Contributor

  1. add stream_type=UserDefined for user defined streams
  2. add stream_type=Internal for pmeta
  3. migrate existing streams' stream.json from v4 to v5
  4. add field stream_type in migration for existing streams
  5. add field stream_type in GET /logstream/{logstream}/info API

self.read()
.expect(LOCK_EXPECT)
.iter()
.filter(|(_, v)| v.stream_type != StreamType::UserDefined)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
.filter(|(_, v)| v.stream_type != StreamType::UserDefined)
.filter(|(_, v)| v.stream_type == StreamType::Internal)

@@ -119,7 +123,7 @@ pub fn stream_name(stream_name: &str) -> Result<(), StreamNameValidationError> {
));
}

if stream_name == INTERNAL_STREAM_NAME {
if *stream_type == StreamType::Internal || stream_name == INTERNAL_STREAM_NAME {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
if *stream_type == StreamType::Internal || stream_name == INTERNAL_STREAM_NAME {
if *stream_type == StreamType::Internal {

1. add stream_type=UserDefined for user defined streams
2. add stream_type=Internal for pmeta
3. migrate existing streams' stream.json from v4 to v5
4. add field stream_type in migration for existing streams
5. add field stream_type in GET /logstream/{logstream}/info API
query server creates internal stream and sync with ingestors on server start
no ingestion can happen from ingestor for internal stream
2. modified sync_streams_with_ingestors that can be used for all streams
@nitisht nitisht merged commit 1b24487 into parseablehq:main Aug 13, 2024
8 checks passed
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.

2 participants