#!/bin/bash

$neighbors
for buddy in $(cat /iri/conf/neighbors); do
  neighbors="$buddy $neighbors"
done
neighbors=${neighbors::-1}

exec java \
  $JAVA_OPTIONS \
  -Xms$MIN_MEMORY -Xmx$MAX_MEMORY \
  -Djava.net.preferIPv4Stack=true \
  -Dlogback.configurationFile=/iri/conf/logback.xml \
  --add-modules java.xml.bind \
  -jar /iri/target/iri*.jar \
  --config /iri/conf/iri.ini \
  --port $API_PORT \
  --udp-receiver-port $UDP_PORT \
  --tcp-receiver-port $TCP_PORT \
  --remote --remote-limit-api "$REMOTE_API_LIMIT" \
  --neighbors "$neighbors" \
  "$@"
  
#!/bin/bash

$neighbors
for buddy in $(cat /iri/conf/neighbors); do
  neighbors="$buddy $neighbors"
done
neighbors=${neighbors::-1}

exec java \
  $JAVA_OPTIONS \
  -Djava.net.preferIPv4Stack=true \
  -Dlogback.configurationFile=/iri/conf/logback.xml \
  --add-modules java.xml.bind \
  -jar /iri/target/iri*.jar \
  --config /iri/conf/iri.ini \
  --port $API_PORT \
  --udp-receiver-port $UDP_PORT \
  --tcp-receiver-port $TCP_PORT \
  --remote --remote-limit-api "$REMOTE_API_LIMIT" \
  --neighbors "$neighbors" \
  "$@"
  

Remove -Xmx and -Xms options because iri uses most of its memory in native memory for rocksdb persistence provider. And -Xms and -Xmx commit physical memory to java heap and avoid the usage by rocksdb. From monitoring heap is quite small and normally is around 1GB
Remove -Xmx and -Xms options because iri uses most of its memory in native memory for rocksdb persistence provider. And -Xms and -Xmx commit physical memory to java heap and avoid the usage by rocksdb. From monitoring heap is quite small and normally is around 1GB
