bookie_jvm_options: >
{% if customize_jvm is defined and customize_jvm|bool %}PULSAR_MEM="{{ pulsar_mem_bookie }}" {% endif %}
PULSAR_EXTRA_OPTS="-XX:+PerfDisableSharedMem"
PULSAR_GC="-XX:+UseG1GC -XX:MaxGCPauseMillis=10"
PULSAR_GC_LOG="-Xlog:gc*,safepoint:{{ tgt_pulsar_gc_log_homedir }}/pulsar_gc_%p.log:time,uptime,tags:filecount=10,filesize=20M"
PULSAR_LOG_DIR="{{ tgt_pulsar_log_homedir }}/bookkeeper
This is not modeled in an optimal way for the systemd migration, #2 .
Instead of using a text field for storing the configuration, a key-value pair (dictionary) data structure should be used.
example of updated configuration:
bookie_jvm_options:
{% if customize_jvm is defined and customize_jvm|bool %}PULSAR_MEM: "{{ pulsar_mem_bookie }}" {% endif %}
PULSAR_EXTRA_OPTS: "-XX:+PerfDisableSharedMem"
PULSAR_GC: "-XX:+UseG1GC -XX:MaxGCPauseMillis=10"
PULSAR_GC_LOG: "-Xlog:gc*,safepoint:{{ tgt_pulsar_gc_log_homedir }}/pulsar_gc_%p.log:time,uptime,tags:filecount=10,filesize=20M"
PULSAR_LOG_DIR: "{{ tgt_pulsar_log_homedir }}/bookkeeper"
The naming should be adjusted too. Instead of calling it _jvm_options, it should be _environment.
Systemd has direct support for setting environment variables.
Currently in https://github.com/datastax/pulsar-ansible#32-customize-pulsar-jvm-settings-log-directory-and-data-directory there's an example:
This is not modeled in an optimal way for the systemd migration, #2 .
Instead of using a text field for storing the configuration, a key-value pair (dictionary) data structure should be used.
example of updated configuration:
The naming should be adjusted too. Instead of calling it
_jvm_options
, it should be_environment
. Systemd has direct support for setting environment variables.