frankjkelly opened a new issue #9251:
URL: https://github.com/apache/pulsar/issues/9251
**Describe the bug**
When I use `pulsar-client consume` and specify the subscription position
(either using `-p` or `--subscription-position`) as `Earliest` the client still
uses `Latest`
**To Reproduce**
In Pulsar 2.6.1
```
$ ./apache-pulsar-2.6.1/bin/pulsar-client --url
pulsar://platform-pulsar-broker:6650 consume -s consumer4a -p Earliest
persistent://cogito-dialog/stf/retrieve4
Warning: Nashorn engine is planned to be removed from a future JDK release
22:10:56.807 [pulsar-client-io-1-1] INFO
org.apache.pulsar.client.impl.ConnectionPool - [[id: 0xc7f51744,
L:/10.101.88.137:52878 -
R:platform-pulsar-broker.cogito-saas.svc.cluster.local/172.20.23.213:6650]]
Connected to server
22:10:56.972 [pulsar-client-io-1-1] INFO
org.apache.pulsar.client.impl.ConsumerStatsRecorderImpl - Starting Pulsar
consumer status recorder with config: {
"topicNames" : [ "persistent://cogito-dialog/stf/retrieve4" ],
"topicsPattern" : null,
"subscriptionName" : "consumer4a",
"subscriptionType" : "Exclusive",
.
.
.
"subscriptionInitialPosition" : "Latest",
```
and
```
$ ./apache-pulsar-2.6.1/bin/pulsar-client --url
pulsar://platform-pulsar-broker:6650 consume -s consumer1
--subscription-position Earliest persistent://cogito-dialog/stf/sometopic
Warning: Nashorn engine is planned to be removed from a future JDK release
22:16:17.871 [pulsar-client-io-1-1] INFO
org.apache.pulsar.client.impl.ConnectionPool - [[id: 0xc28a8203,
L:/10.101.88.137:58782 -
R:platform-pulsar-broker.cogito-saas.svc.cluster.local/172.20.23.213:6650]]
Connected to server
22:16:17.987 [pulsar-client-io-1-1] INFO
org.apache.pulsar.client.impl.ConsumerStatsRecorderImpl - Starting Pulsar
consumer status recorder with config: {
"topicNames" : [ "persistent://cogito-dialog/stf/sometopic" ],
.
.
.
"subscriptionInitialPosition" : "Latest",
```
**Expected behavior**
Subscription Position default is overridden
**Screenshots**
See above
**Desktop (please complete the following information):**
- OS: Linux
- Pulsar: 2.6.1
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]