{"id":37023524,"url":"https://github.com/sbridges/beacon","last_synced_at":"2026-01-14T02:49:45.371Z","repository":{"id":55590034,"uuid":"239233646","full_name":"sbridges/beacon","owner":"sbridges","description":"A library and java agent for exposing JFR events over JMX","archived":false,"fork":false,"pushed_at":"2022-12-14T20:43:29.000Z","size":98,"stargazers_count":8,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-11T19:35:11.806Z","etag":null,"topics":["java","jfr","jfr-event","jmx"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sbridges.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-02-09T02:14:19.000Z","updated_at":"2024-11-28T23:01:38.000Z","dependencies_parsed_at":"2023-01-29T01:00:40.440Z","dependency_job_id":null,"html_url":"https://github.com/sbridges/beacon","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/sbridges/beacon","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbridges%2Fbeacon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbridges%2Fbeacon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbridges%2Fbeacon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbridges%2Fbeacon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sbridges","download_url":"https://codeload.github.com/sbridges/beacon/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbridges%2Fbeacon/sbom","scorecard":{"id":802837,"data":{"date":"2025-08-11","repo":{"name":"github.com/sbridges/beacon","commit":"8451a17598c01ca961da59d66c526c372e5209bf"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/24 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 4 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":2,"reason":"8 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-3mc7-4q67-w48m","Warn: Project is vulnerable to: GHSA-98wm-3w3q-mw94","Warn: Project is vulnerable to: GHSA-9w3m-gqgf-c4p9","Warn: Project is vulnerable to: GHSA-c4r9-r8fh-9vj2","Warn: Project is vulnerable to: GHSA-hhhw-99gj-p3c3","Warn: Project is vulnerable to: GHSA-mjmj-j48q-9wg2","Warn: Project is vulnerable to: GHSA-rvwf-54qp-4r6v","Warn: Project is vulnerable to: GHSA-w37g-rhq8-7m4j"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-23T10:57:35.781Z","repository_id":55590034,"created_at":"2025-08-23T10:57:35.781Z","updated_at":"2025-08-23T10:57:35.781Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408773,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","jfr","jfr-event","jmx"],"created_at":"2026-01-14T02:49:44.853Z","updated_at":"2026-01-14T02:49:45.360Z","avatar_url":"https://github.com/sbridges.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"Beacon\n======\n\nBeacon exposes [JFR](https://openjdk.java.net/jeps/349) events and stats over [JMX](https://openjdk.java.net/groups/jmx/).\n\nUsing Beacon you can use jconsole to connect to a running jvm and answer questions like :\n \n - What files are my jvm writing to\n - What remote hosts are my jvm talking to\n - What classes are taking up most of my heap\n\nRequirements\n============\n\nBeacon relies on [JFR Event Streaming](https://openjdk.java.net/jeps/349) which is only available in Java 14 and later.\n\nInstalling\n==========\n\nAdd a dependency using maven\n\n\n    \u003cdependency\u003e\n      \u003cgroupId\u003ecom.github.sbridges\u003c/groupId\u003e\n      \u003cartifactId\u003ebeacon\u003c/artifactId\u003e\n      \u003cversion\u003e${version}\u003c/version\u003e\n    \u003c/dependency\u003e\n\nRunning\n=======\n\nBeacon can be run in two modes.  You can call Beacon programmatically using code like,\n\n      var beacon = new Beacon();\n      beacon.start();\n\nOr by using Beacon as a java agent by adding the following argument to your java command,\n\n     -javaagent:\u003cpath-to-beacon-jar-file\u003e\n\n\nMXBeans exposed by beacon\n=========================\n\nInspector\n---------\n\nCaptures the latest Event as a String.  This is useful for debgging and exploring events.\n\nGauge\n-----\n\nCaptures the last value.\n\nFor example, you use this to expose the jdk.CPULoad#machineTotal field.\n\nRate\n----\n\nCaptures the rate of change of a value.  \n\nFor example, you can capture the exceptions per second being thrown in jvm using jdk.ExceptionStatistics#throwables.  \n\nYou can also sum values from multiple events.  For example getting the rate of all network writes by summing the jdk.SocketRead#bytesRead from all events.\n\nTop\n---\n\nCaptures the name/value pairs sorted by value over the previous sampling interval, similar to the unix top command. \n\nFor example, you can use jdk.ObjectCount#objectClass and jdk.ObjectCount#count to\nshow how many instances of each class you have (limited to those which take up some percentage of the heap)\n\nTopSum\n------\n\nSimilar to top but this sums the values of all events with the same nane, rather than using the value of the last event.  \n\nFor example, you can use jdk.FileRead#path and jdk.FileRead#bytesRead to see which files are being read by the jvm.\n\nHistogram\n---------\n\nExposes a Histogram of a value, both over the last\nminute and over all time.\n\n\nConfiguration with yaml\n===========\n\nThe mapping between JFR events and JMX beans can be configured using yaml.\n\nBy default, Beacon will load [beacon-default.yaml](https://github.com/sbridges/beacon/blob/master/src/main/resources/com/github/sbridges/beacon/beacon-default.yaml) which is included in the beacon jar file.\n\nTo change the default configuration, start your jvm either using,\n\n    -Dcom.github.sbridges.beacon.conf.path=\u003cfull path to a yaml configuration file\u003e\n\nOr\n\n    -Dcom.github.sbridges.beacon.conf.resouce=\u003cresource on the classpath\u003e\n\n`\u003cresource on the classpath\u003e` will be loaded using `Beacon.class.getResourceAsStream()`\n\nConfiguration programmatically\n===============\n\nIf you are using beacon as a library, and not as a java agent, you can provide Beacon a configuration String through the `Beacon(String)` constructor,\nor you can programmatically create an instance using the `Beacon(List\u003cBean\u003e beans, List\u003cEventConfig\u003e events)` constructor.\n\n\nConfiguration yaml file format\n-------------------------------\n\nBeacon can be configured using a yaml file.  \n\nSee [beacon-default.yaml](https://github.com/sbridges/beacon/blob/master/src/main/resources/com/github/sbridges/beacon/beacon-default.yaml) for an example.\n\nThe top-level of the yaml is a map with two keys, events and objects.\n\n      events : [ \u003clist of Events\u003e ]\n      objects : [ \u003clist of Objects\u003e ]\n\nEvents\n------\n\nevents is a list of Maps.  Where each map describes a JFR event to monitor.\n\nAs an example,\n\n      events :\n         - eventName : jdk.ExceptionStatistics\n           eventPeriod : {seconds : 5}\n\nThe allowed keys for each event are :\n\n| Name | Description | Required |\n| -----|-------------|---------|\n|eventName | The name of the JFR Event| Yes |\n|eventPeriod |If present how often the jvm should emit this event. Format is {\\\u003ctimeUnit\u003e : \\\u003cvalue\u003e}, for example {seconds : 5}. | No, defaults to no period |\n|  eventThreshold  |  If present, the jvm should only  emit events with a duration greater than threshold. Format is {\\\u003ctimeUnit\u003e : \\\u003cvalue\u003e}, for example {seconds : 5}.  | No, defaults to no threshold |\n| stackTrace | If present, should these events capture their stack traces. | No, defaults to false |\n\nObjects \n------\n\nEach Object must have two key which describe the object type, and may have other keys which configures the bean.  The required keys are :\n\n| Name | Description | Required |\n| -----|-------------|---------|\n| objectName | The JMX [ObjectName](https://docs.oracle.com/en/java/javase/13/docs/api/java.management/javax/management/ObjectName.html) that this bean is bound to. | Yes |\n| objectType | The type of the object, one of gauge, inspector, rate, top, topSum or histogram. | Yes |\n\nGauge\n-----\n\nA gauge is configured with a values key which lists the JFR events to listen for.  For example :\n\n       - objectName : com.github.sbridges.beacon:event=jdk.CPULoad,field=jvmUser\n         objectType : gauge\n         values :\n           - event : jdk.CPULoad\n             field : jvmUser\n\n\nInspector\n---------\n\nAn inspector is configured with an events key which gives the event to inspect, and optionally an InspectorConfig which specifies the number of objects to keep.\n\nFor example :\n\n    - objectName : com.github.sbridges.beacon:event=Test\n      objectType : inspector\n      event : jdk.ExceptionStatistics \n      inspectorConfig :\n         size : 10\n\nRate Config fields are :\n\n| Name | Description | Required |\n| -----|-------------|---------|\n| size | The number of events to keep, as new events arrive older ones are discarded. | No, defaults to 1 |\n\nRate\n----\n\nif the objectType is rate, the Object may have a rateConfig key and must have a values key listing the events and fields to watch.  For example :\n\n    - objectName : com.github.sbridges.beacon:event=AllocationRate\n      objectType : rate\n      rateConfig :\n        sum : true\n        period : {seconds : 10}\n      values :\n          - event : jdk.ObjectAllocationOutsideTLAB\n            field : allocationSize\n          - event : jdk.ObjectAllocationInNewTLAB\n            field : tlabSize\n\nRate Config fields are :\n\n| Name | Description | Required |\n| -----|-------------|---------|\n| sum | If set to true, then this rate will sum the value seen by all events, rather than take the value of the last event. Defaults to false.  See rate documentation above for examples. | No, defaults to false |\n| period | Rate is calculated at most once every period. Format is {\\\u003ctimeUnit\u003e : \\\u003cvalue\u003e}, for example {seconds : 2}. | No, defaults to 5 seconds |\n\nTop/TopSum\n-----------\n\nTop/Top sum require a keyValues key which declares which events to listen to, and optionall a topConfig key which configures the top/topSum\n\nAn example of a TopSum declaration is\n\n       - objectName : com.github.sbridges.beacon:event=jdk.SocketRead,by=byHostPort\n         objectType : topSum\n         topConfig :\n           period : {seconds : 5}\n         keyValues :\n           - event : jdk.SocketRead\n             keyFields : [host, port]\n             valueField : bytesRead\n             \nAn example of a Top declaration is,\n\n       - objectName : com.github.sbridges.beacon:event=jdk.ObjectCount,field=totalSize\n         objectType : top\n         topConfig :\n           period : {seconds : 60}\n         keyValues :\n           - event : jdk.ObjectCount\n             keyFields : [objectClass]\n             valueField : totalSize\n\ntopConfig allows the following keys :\n\n| Name | Description | Required |\n| -----|-------------|---------|\n| period | The top list is recalculated at most once every period.  | No, defaults to 5 seconds |\n\nHistogram\n---------\n\nIf the objectType is histogram, it must have a values key which describes the events of the histogram\n\nAs an example :\n\n        - objectName : com.github.sbridges.beacon:event=jdk.SocketRead,type=histo\n            objectType : histogram\n            values : \n               - event : jdk.SocketRead\n                 field : bytesRead\n\n\n\nGetting information about JFR events for your jvm\n=================================================\n\nStart your jvm and get a recording file using the command,\n\n    jcmd \u003cPID\u003e JFR.dump filename=/tmp/recording.tmp.jfr\n\nAfter getting a recording, you can use the jfr command to list the types of JFR events registered in the jvm that created the file with the command,\n\n     jfr metadata /tmp/recording.tmp.jfr\n\nThis includes data for all events that this JVM can produce.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbridges%2Fbeacon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsbridges%2Fbeacon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbridges%2Fbeacon/lists"}