-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove sigar from JvmMonitor #33
Conversation
|
||
import com.metamx.common.RE; | ||
import java.lang.management.ManagementFactory; | ||
import java.util.regex.Pattern; | ||
|
||
/** | ||
* For systems that for whatever reason cannot use Sigar (through com.metamx.metrics.cgroups.SigarPidDiscoverer ), | ||
* For systems that for whatever reason cannot use Sigar (through com.metamx.metrics.SigarPidDiscoverer ), | ||
* this attempts to get the PID from the JVM "name". | ||
*/ | ||
public class JvmPidDiscoverer implements PidDiscoverer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe add a static method to not always force to create an object JvmPidDiscoverer?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant a static method that just returns Pid, but it works too
|
||
import com.metamx.common.RE; | ||
import java.lang.management.ManagementFactory; | ||
import java.util.regex.Pattern; | ||
|
||
/** | ||
* For systems that for whatever reason cannot use Sigar (through com.metamx.metrics.cgroups.SigarPidDiscoverer ), | ||
* For systems that for whatever reason cannot use Sigar (through com.metamx.metrics.SigarPidDiscoverer ), | ||
* this attempts to get the PID from the JVM "name". | ||
*/ | ||
public class JvmPidDiscoverer implements PidDiscoverer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant a static method that just returns Pid, but it works too
No description provided.