{"id":27996586,"url":"https://github.com/runtimetools/javametrics","last_synced_at":"2026-03-17T08:34:30.924Z","repository":{"id":22234599,"uuid":"94986865","full_name":"RuntimeTools/javametrics","owner":"RuntimeTools","description":"Application Metrics for Java™ instruments the Java runtime for performance monitoring, providing the monitoring data visually with its built in dashboard","archived":false,"fork":false,"pushed_at":"2022-07-11T21:06:06.000Z","size":1832,"stargazers_count":23,"open_issues_count":11,"forks_count":14,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-08-02T15:23:11.121Z","etag":null,"topics":["agent","application-metrics","dashboard","debug","java","java-8","java-application-metrics","java-sdk","java8","metrics","metrics-gathering","metrics-visualization","monitoring","monitoring-data","performance-metrics","performance-monitoring","performance-visualization","websphere-liberty"],"latest_commit_sha":null,"homepage":"https://developer.ibm.com/javasdk/application-metrics-java/","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/RuntimeTools.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-21T09:26:25.000Z","updated_at":"2024-09-11T07:31:12.000Z","dependencies_parsed_at":"2022-08-07T10:15:23.755Z","dependency_job_id":null,"html_url":"https://github.com/RuntimeTools/javametrics","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/RuntimeTools/javametrics","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RuntimeTools%2Fjavametrics","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RuntimeTools%2Fjavametrics/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RuntimeTools%2Fjavametrics/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RuntimeTools%2Fjavametrics/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RuntimeTools","download_url":"https://codeload.github.com/RuntimeTools/javametrics/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RuntimeTools%2Fjavametrics/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274744018,"owners_count":25341136,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-12T02:00:09.324Z","response_time":60,"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":["agent","application-metrics","dashboard","debug","java","java-8","java-application-metrics","java-sdk","java8","metrics","metrics-gathering","metrics-visualization","monitoring","monitoring-data","performance-metrics","performance-monitoring","performance-visualization","websphere-liberty"],"created_at":"2025-05-08T21:46:40.983Z","updated_at":"2026-03-17T08:34:30.894Z","avatar_url":"https://github.com/RuntimeTools.png","language":"Java","funding_links":[],"categories":["指标库"],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/RuntimeTools/javametrics.svg?branch=master)](https://travis-ci.org/RuntimeTools/javametrics)\n[![codebeat badge](https://codebeat.co/badges/02e01f80-46ee-4a25-a409-ff1c65cb1421)](https://codebeat.co/projects/github-com-runtimetools-javametrics-master)\n[![codecov](https://codecov.io/gh/RuntimeTools/javametrics/branch/master/graph/badge.svg)](https://codecov.io/gh/RuntimeTools/javametrics)\n![Apache 2](https://img.shields.io/badge/license-Apache2-blue.svg?style=flat)\n[![Homepage](https://img.shields.io/badge/homepage-Application%20Metrics%20for%20Java-blue.svg)](https://developer.ibm.com/javasdk/application-metrics-java/)\n\n# Application Metrics for Java\u0026trade;\n\nApplication Metrics for Java\u0026trade; instruments the Java runtime for performance monitoring, providing the monitoring data visually with its built in dashboard\n\nThe following data collection sources are built-in:\n\n Source             | Description\n:-------------------|:-------------------------------------------\n Environment        | Machine and runtime environment information\n CPU                | Process and system CPU\n GC                 | Percentage time spent in garbage collection\n Memory             | Java native and non-native memory usage\n HTTP               | HTTP request information\n\n\n## Getting Started\n### Prerequisites\n\nThe Application Metrics for Java agent requires Java version 8.\n\n\u003ca name=\"install\"\u003e\u003c/a\u003e\n\n### Releases\n\nDownload the latest Application Metrics for Java release zip from [Github](http://github.com/runtimetools/javametrics/releases).\nThis contains:\n* `webapp/dashboard/javametrics-dash-x.x.x.war` - Javametrics Web Application\n* `webapp/prometheus/javametrics-prometheus-x.x.x.war` - Javametrics Prometheus Endpoint\n* `agent/javametrics-agent-x.x.x.jar` - Javametrics agent and required ASM libraries\n* `spring/javametrics-spring-x.x.x.jar` - Javametrics spring\n* `rest/javametrics-rest-x.x.x.war` - Javametrics REST api package\n\n### Building with Maven\n\nTo build with maven\n\n```\ngit clone --recursive https://github.com/RuntimeTools/javametrics\ncd javametrics\nmvn install\n```\n\nTo use the agent built locally, you will need to reference the your local javametrics directory when setting the javaagent parameter later in the instructions.\n\n\nJavametrics is also released on Maven Central with the following artifacts\n\n\n```\njavametrics-agent\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-agent\u003c/artifactId\u003e\n\njavametrics-dash\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-dash\u003c/artifactId\u003e\n\njavametrics-prometheus\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-prometheus\u003c/artifactId\u003e\n\njavametrics-spring\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-spring\u003c/artifactId\u003e\n\njavametrics-rest\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-rest\u003c/artifactId\u003e\n\njavametrics-codewind\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-codewind\u003c/artifactId\u003e\n\njavametrics-codewind-spring\n \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n \u003cartifactId\u003ejavametrics-codewind-spring\u003c/artifactId\u003e\n```\n\n### Websphere Liberty\nUnpack the release `.zip` archive that you downloaded in the previous step.  \n\nJavametrics requires a Java option to be set in order to load the agent.  A [jvm.options](https://www.ibm.com/support/knowledgecenter/en/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/twlp_admin_customvars.html) file is the best way to configure this for Websphere Liberty. It should contain the following entry, where `path_to_javametrics_agent_dir` is replaced with the actual path containing the javametrics file:\n\n```\n# Load Javametrics Java agent\n-javaagent:\u003cpath_to_javametrics_agent_dir\u003e/javametrics-agent-1.8.0.jar\n```\nIf you have built the agent locally, your path_to_javametrics_agent_dir will need to point to your clone of javametrics.\ne.g.\n```\n-javaagent:\u003cpath_to_git_home\u003e/javametrics/javaagent/target/javametrics-agent-1.8.0.jar\n```\n* NOTE, if you move the javametrics-agent to another directory you need to make sure you take the asm folder with it.  The asm folder is required for the agent to run as it contains files that the agent needs\n\nCopy the required war files into your [Websphere Liberty](https://developer.ibm.com/wasdev/websphere-liberty/) 'dropins' directory.\n- `javametrics-dash-x.x.x.war` to use the Javametrics dashboard\n- `javametrics-rest-x.x.x.war` to use the Javametrics REST api\n- `javametrics-prometheus-x.x.x.war` to use Prometheus support\n\nThe URL for the dashboard consists of the server's default HTTP endpoint plus `/javametrics-dash/`.  E.g. Running locally it might be: http://localhost:9080/javametrics-dash/\n\nThe URL for the prometheus endpoint consists of the server's default HTTP endpoint plus the default prometheus metrics path `/metrics`.  E.g. Running locally it might be: http://localhost:9080/metrics/\n\nThe URL for the REST API context root consists of the server's default HTTP endpoint plus `/javametrics`.  E.g. Running locally it might be: http://localhost:9080/javametrics/api/v1/collections\n\n### Open Liberty\n\nFollow all the steps for [Websphere Liberty](#websphere-liberty) and in addition, make sure that the `websocket-1.0` feature is installed on the server. To do this, open the `server.xml` for the server in question, and in the `\u003cfeatureManager\u003e` tags add the following line\n```xml\n\u003cfeature\u003ewebsocket-1.0\u003c/feature\u003e\n```\n\n### Spring Boot\nTo enable Javametrics in a Spring Boot application you need to add an extra annotation to your main application class:\n```\n@ComponentScan(basePackages = {\"com.ibm.javametrics.spring\", \"mypackage\"})\n```\nIn a Spring Boot starter project this goes above or below the `@SpringBootApplication` annotation and you will need to add the package that that class is in to the list of `basePackages` (in place of __mypackage__ above).\n\nYou also need to add the following dependencies to your pom.xml:\n\n```\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n    \u003cartifactId\u003ejavametrics-spring\u003c/artifactId\u003e\n    \u003cversion\u003e1.8.0\u003c/version\u003e\n\u003c/dependency\u003e\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.ibm.runtimetools\u003c/groupId\u003e\n    \u003cartifactId\u003ejavametrics-agent\u003c/artifactId\u003e\n    \u003cversion\u003e1.8.0\u003c/version\u003e\n\u003c/dependency\u003e\n\u003cdependency\u003e\n    \u003cgroupId\u003eorg.glassfish\u003c/groupId\u003e\n    \u003cartifactId\u003ejavax.json\u003c/artifactId\u003e\n    \u003cversion\u003e1.0.4\u003c/version\u003e\n\u003c/dependency\u003e\n ```\n\nOnce you have launched your application you will find the dashboard at the server's default HTTP endpoint plus `/javametrics-dash/`.  E.g. running locally with Spring Boot it might be: http://localhost:8080/javametrics-dash/\n\nThe URL for the REST API context root consists of the server's default HTTP endpoint plus `/javametrics/`.  e.g. http://localhost:9080/javametrics/api/v1/collections\n\n### Apache Tomcat\nComing soon\n\n\u003ca name=\"api-doc\"\u003e\u003c/a\u003e\n\n## API Documentation\n- [API Documentation](API-DOCUMENTATION.md)\n\n## REST API Documentation\n- [REST API](REST-API.md)\n\n\u003ca name=\"building\"\u003e\u003c/a\u003e\n\n## Source code\nThe source code for Application Metrics for Java is available in the [Javametrics Github project](http://github.com/RuntimeTools/javametrics).\n\n## License\nThis project is released under an Apache 2.0 open source license.  \n\n## Versioning scheme\nThis project uses a semver-parsable X.0.Z version number for releases, where X is incremented for breaking changes to the public API described in this document and Z is incremented for bug fixes **and** for non-breaking changes to the public API that provide new function.\n\n## Version\n1.8.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fruntimetools%2Fjavametrics","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fruntimetools%2Fjavametrics","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fruntimetools%2Fjavametrics/lists"}