If you're using ECK, by default pods will automatically be assigned half of ram (pod ram assignment) as heap. You can override this setting via env variable
ES_JAVA_OPS
Example of how elastickonductor sets it the heap value. ElasticKonductor/es.yaml at main · sunileman/ElasticKonductor · GitHub
can you share your k8s manifest? I suspect you need to jack up your pod memory which will help increase your heap size.