79185437

Date: 2024-11-13 14:56:57
Score: 1
Natty:
Report link

Apache NiFi allows you to configure environment variables that can be accessed by processors. You can set the server's timezone as an environment variable, for example: bash Copy code export TZ="Asia/Colombo" Then, in your NiFi processor, you can access this environment variable using NiFi Expression Language: text Copy code ${env:TZ} Use NiFi System Properties:

You can pass the timezone as a system property to NiFi by modifying the nifi.properties file or setting a JVM property. Add the following line to nifi.properties or configure it as a JVM parameter:

-Duser.timezone=Asia/Colombo

Then, in a processor, use:

${sys:timezone}

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: kaxun