java:
  pkg:
    - installed
    {% if grains['os_family'] == 'Debian'%}
    - name: default-jre
    {% endif %}

java:
  pkg:
    - installed
    - name: {{ pillar['java'] }}

Move java package name logic to pillar
Move java package name logic to pillar

jesusaurus/hpcs-salt-state,jesusaurus/hpcs-salt-state