crossoverJie opened a new issue, #21766:
URL: https://github.com/apache/pulsar/issues/21766

   ### Search before asking
   
   - [X] I searched in the [issues](https://github.com/apache/pulsar/issues) 
and found nothing similar.
   
   
   ### Version
   
   3.0.2
   
   ### Minimal reproduce step
   
   
![image](https://github.com/apache/pulsar/assets/15684156/8a141d20-7d5c-4085-a1eb-eb42a070796f)
   
![image](https://github.com/apache/pulsar/assets/15684156/70e1143b-03d6-4e11-832b-fd889c69fdd0)
   
   Details:
   - bookkeeper_server_ADD_ENTRY_REQUEST
   - bookkeeper_server_ADD_ENTRY_BLOCKED
   - bookkeeper_server_READ_ENTRY_BLOCKED
   - bookie_journal_JOURNAL_CB_QUEUE_SIZE
   - bookie_read_cache_hits_count
   - bookie_read_cache_misses_count
   - bookie_DELETED_LEDGER_COUNT
   - bookie_MAJOR_COMPACTION_COUNT
   
   ### What did you expect to see?
   
   The metrics is normal.
   
   ### What did you see instead?
   
   Miss some metrics.
   
   ### Anything else?
   
   When I downgraded the `bookkeeper` version to 2.11.2, the version of 
bookkeepe used was `4.15.4`, and everything was normal.
   
   However, when I used BookKeeper `4.16.3` locally with Pulsar 3.x, I could 
not reproduce the issue.
   
   Whether using source code or Docker: `apache/bookkeeper:4.16.3`, I was 
unable to reproduce it.
   
   This is my test code:
   
   ```java
       @SneakyThrows
       @Test
       public void testBk2() {
           String connectionString = "127.0.0.1:2181"; // For a single-node, 
local ZooKeeper cluster
           ClientConfiguration config = new ClientConfiguration();
           config.setZkServers(connectionString);
           config.setAddEntryTimeout(2000);
           BookKeeper bookKeeper = new BookKeeper(config);
           byte[] password = "some-password".getBytes();
           bookKeeper.asyncCreateLedger(1, 1,
                   1, BookKeeper.DigestType.MAC, password, new 
AsyncCallback.CreateCallback() {
                       @SneakyThrows
                       @Override
                       public void createComplete(int rc, LedgerHandle lh, 
Object ctx) {
                           log.info("create complete: {}", rc);
   
                           for (int i = 0; i < 100000; i++) {
                               lh.asyncAddEntry("some-data".getBytes(), new 
AsyncCallback.AddCallback() {
                                   @Override
                                   public void addComplete(int rc, LedgerHandle 
lh, long entryId, Object ctx) {
                                       log.info("rc: {}, entryId: {}", rc, 
entryId);
                                   }
                               }, null);
   
                               TimeUnit.SECONDS.sleep(1);
                           }
   
                       }
                   }, null, null);
   
           TimeUnit.SECONDS.sleep(100);
       }
   }
   ```
   
   
![image](https://github.com/apache/pulsar/assets/15684156/8158512e-cdcb-44c9-96fd-193e227ebbef)
   
   
   
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to