criteo / babar

Profiler for large-scale distributed java applications (Spark, Scalding, MapReduce, Hive,...) on YARN.
Apache License 2.0
125 stars 29 forks source link

Character / is not accepted for directory name by agent #18

Closed andres-lago closed 6 years ago

andres-lago commented 6 years ago

Sometimes you can need to specify to babar-agent a directory to save the babar.log file. If the directory contains the symbol "/", the agent crashes. Example:

-javaagent:./babar-agent-0.2.0-SNAPSHOT.jar=dir=/tmp,StackTraceProfiler[profilingMs=60000,reportingMs=60000],JVMProfiler[profilingMs=60000,reservedMB=10376],ProcFSProfiler[profilingMs=60000]"

The correction is quite simple, you must modify ligne 45 of com/criteo/babar/agent/config/AgentConfig.java :

and rebuild babar-agent.

BenoitHanotte commented 6 years ago

Hello @andres-lago, thanks a lot for reporting the issue! I fixed it with PR #19 that was just merged :)