{"id":16445335,"url":"https://github.com/lloydmeta/jhhi","last_synced_at":"2025-03-23T08:32:13.532Z","repository":{"id":55771615,"uuid":"320164425","full_name":"lloydmeta/jhhi","owner":"lloydmeta","description":"Java Heap Histogram Ingest, written in Rust. Sends jmap heap histograms to Elasticsearch.","archived":false,"fork":false,"pushed_at":"2020-12-12T10:20:05.000Z","size":1345,"stargazers_count":6,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-18T19:29:13.410Z","etag":null,"topics":["elasticsearch","heap","ingest","java","kibana","rust","rust-lang"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lloydmeta.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-12-10T04:59:58.000Z","updated_at":"2023-08-23T13:02:18.000Z","dependencies_parsed_at":"2022-08-15T07:00:19.208Z","dependency_job_id":null,"html_url":"https://github.com/lloydmeta/jhhi","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lloydmeta%2Fjhhi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lloydmeta%2Fjhhi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lloydmeta%2Fjhhi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lloydmeta%2Fjhhi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lloydmeta","download_url":"https://codeload.github.com/lloydmeta/jhhi/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245078067,"owners_count":20557274,"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","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":["elasticsearch","heap","ingest","java","kibana","rust","rust-lang"],"created_at":"2024-10-11T09:44:05.614Z","updated_at":"2025-03-23T08:32:12.991Z","avatar_url":"https://github.com/lloydmeta.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"## jhhi [![Continuous integration](https://github.com/lloydmeta/jhhi/workflows/Continuous%20integration/badge.svg)](https://github.com/lloydmeta/jhhi/actions?query=workflow%3A%22Continuous+integration%22)\n\nJava Heap Histogram Ingest\n\n![Kibana](kibana.png)\n\n- Send a single histogram or all histograms in a directory\n  - Attempts to parse a timestamp in the following order per file\n    1. RFC3339 parse of file name\n    2. File created at timestamp\n    3. File modified at timestamp\n- Supports URL or Cloud ID\n- Supports different auths (Basic, Api Key)\n- Uses the [Bulk API](https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-bulk.html)\n- Uses the [official Elasticsearch client](https://github.com/elastic/elasticsearch-rs)\n\n## Install\n\n`cargo install jhhi` or download from [releases page](https://github.com/lloydmeta/jhhi/releases).\n\n### Usage\n\nCreate some histos for the Java process at `$JAVA_PID` and ingest them:\n\n```bash\nwhile true; do\n    jmap -histo:live,file=$(date +%Y-%m-%dT%T%z) $JAVA_PID\n    sleep 5\ndone\n```\n\n```shell\njhhi\\\n  --dir ~/Desktop/histograms_busy \\\n  --api-key-id REDACTED \\\n  --api-key REDACTED \\\n  --cloud-id REDACTED\n\nHistograms will be indexed into [jheap-histo-ingest_2020-12-10t04-11-48.108146+00-00]\nOpening dir [\"/Users/lloyd/Desktop/histograms_busy\"]\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:06:37+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14324/14324   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:16+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14393/14393   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:00+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14387/14387   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:06:31+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14400/14400   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:50+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14404/14404   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:11+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14489/14489   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:45+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14403/14403   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:28+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14422/14422   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:06:48+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14493/14493   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:33+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14405/14405   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:05+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14345/14345   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:22+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14399/14399   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:06:54+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14482/14482   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:06:43+0000\"] as histogram, sending ...\n  [00:00:11] ########################################   14406/14406   Done\nParsed [\"/Users/lloyd/Desktop/histograms_busy/2020-12-10T04:07:39+0000\"] as histogram, sending ...\n  [00:00:10] ########################################   14398/14398   Done\n```\n\nVars can be passed as flags or environment variables; use `--help` to see options.\n\n```shell\njhhi [jheap-histo-ingest] 0.1.0\nIngests Java heap histograms from the jmap util to Elasticsearch\n\nUSAGE:\n    jhhi [OPTIONS] --dir \u003cdir\u003e --file \u003cfile\u003e\n\nFLAGS:\n    -h, --help       Prints help information\n    -V, --version    Prints version information\n\nOPTIONS:\n        --api-key \u003capi-key\u003e          API key auth: API Key [env: JHHI_ES_API_KEY=]\n        --api-key-id \u003capi-key-id\u003e    API key auth: API Key Id [env: JHHI_ES_API_KEY_id=]\n        --chunk-size \u003cchunk-size\u003e    Ingest bulk size [env: JHHI_ES_BULK_SIZE=]  [default: 500]\n        --cloud-id \u003ccloud-id\u003e        Cloud Id for the cluster to send data to [env: JHHI_ES_CLOUD_ID=]\n    -d, --dir \u003cdir\u003e                  Directory holding histogram files to ingest. Should be passed if file is not [env:\n                                     JHHI_HISTO_DIR=]\n    -f, --file \u003cfile\u003e                Histogram file to ingest. Should be passed if dir is not [env: JHHI_HISTO_FILE=]\n        --index-name \u003cindex-name\u003e    Target index name [env: JHHI_ES_INDEX_NAME=]\n        --password \u003cpassword\u003e        Basic auth: password [env: JHHI_ES_PASSWORD=]\n        --url \u003curl\u003e                  Url for the cluster to send data to [env: JHHI_ES_URL=]\n        --user \u003cuser\u003e                Basic auth: username [env: JHHI_ES_USER=]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flloydmeta%2Fjhhi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flloydmeta%2Fjhhi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flloydmeta%2Fjhhi/lists"}