java.util.concurrent.atomic · java.base · since Java 1.5

AtomicLong

declaration
public class AtomicLong extends Number implements Serializable

The 64-bit atomic counter. For write-hot counters under contention, LongAdder scales better; AtomicLong wins when you need exact reads between writes.