apache / apache/pulsar

Usage of java.time.Clock for timestamps isn't consistently performed in Pulsar code base

Open
#25,660 4 comments 0 reactions 0 assignees View on GitHub
area/scalable-topics
Dominant language
Java
Stars
15.3k
Forks
3.8k
Avg merge
1d 14h
Merged PRs (30d)
160

Description

In some of the existing code locations, PulsarService's `java.time.Clock clock` field is used for timestamps, however it's not consistently applied in the code base. Would it be useful to use `java.time.Clock` for timestamps?

_Originally posted by @lhotari in https://github.com/apache/pulsar/pull/25658#discussion_r3178499222_

Contributor guide

Open the contributing guide

Research direction

Start by locating PulsarService's java.time.Clock field and inventorying the other timestamp-producing code locations in the Pulsar code base. Determine which locations bypass the clock, then define completion as consistent clock usage across the identified cases with appropriate validation; the issue names no files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
distributed-systems
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.