apache / apache/pulsar-client-node

Creating a subscription with initial position as "earliest"

Open
#92 3 comments 0 reactions 0 assignees View on GitHub
triage/week-23 type/feature
Dominant language
C++
Stars
164
Forks
98
PR merge metrics
No merged PRs in 30d

Description

My use case: I have a shared subscription with a bunch of consumers. Suppose, all the consumers die and there are messages still being published to the topic. When a new consumer comes in, I want it to read from the last unacknowledged message so that no messages are lost or unprocessed.

So, I want to create a subscription with initial subscription position as `earliest` but I don't see any option to set the initial position. Also, What is default behavior? `earliest` or `latest` ?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the subscription-creation API in the NodeJS client and tracing how its initial position is selected. Check the existing behavior and documentation for the default, then define the option and verify that a new consumer can begin at the requested position without losing unacknowledged messages.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
distributed-systems
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.