Hello Sajal!
Z GC is known (or prone) for numerous allocation stalls. You may want to experiment with Z GC algorithm only for very large heap size (i.e., >100 GB). Since your heap size is only 31GB, you may consider using G1 GC algorithm.
I am seeing allocation stall even on free heap
Heap size 31 GB
GC log :
Edit your Comment