{"id":23469890,"url":"https://github.com/vapor-ware/synse-juniper-jti-plugin","last_synced_at":"2025-07-07T15:33:12.486Z","repository":{"id":45445676,"uuid":"261306204","full_name":"vapor-ware/synse-juniper-jti-plugin","owner":"vapor-ware","description":"Synse plugin for Juniper JTI metrics over UDP stream","archived":false,"fork":false,"pushed_at":"2021-12-13T16:10:44.000Z","size":96,"stargazers_count":0,"open_issues_count":3,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-21T22:03:07.885Z","etag":null,"topics":["jti","juniper","synse","synse-plugin","udp"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vapor-ware.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-05-04T22:07:25.000Z","updated_at":"2021-12-13T16:10:45.000Z","dependencies_parsed_at":"2022-08-04T15:15:49.803Z","dependency_job_id":null,"html_url":"https://github.com/vapor-ware/synse-juniper-jti-plugin","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/vapor-ware%2Fsynse-juniper-jti-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vapor-ware%2Fsynse-juniper-jti-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vapor-ware%2Fsynse-juniper-jti-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vapor-ware%2Fsynse-juniper-jti-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vapor-ware","download_url":"https://codeload.github.com/vapor-ware/synse-juniper-jti-plugin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248647256,"owners_count":21139081,"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":["jti","juniper","synse","synse-plugin","udp"],"created_at":"2024-12-24T15:36:46.200Z","updated_at":"2025-04-12T23:46:17.185Z","avatar_url":"https://github.com/vapor-ware.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://build.vio.sh/buildStatus/icon?job=vapor-ware/synse-juniper-jti-plugin/master)](https://build.vio.sh/blue/organizations/jenkins/vapor-ware%2Fsynse-juniper-jti-plugin/activity)\n\n# Synse Juniper JTI Plugin\n\nSynse plugin for Juniper JTI metrics over UDP stream.\n\nThis plugin ingests Juniper metrics over a UDP stream, making them available to the\nSynse platform. Juniper supports many sensors/resources, not all of which are yet\nsupported by the plugin. Current plugin capabilities include support for the following\nresources:\n\n* `/junos/system/linecard/interface/`\n* `/junos/system/linecard/optics/`\n\nThe plugin has been tested against Juniper routers running Junos OS 18.2R3. Compatibility\nwith other Junos versions is not guaranteed.\n\n## Getting Started\n\n### Getting\n\nYou can install the plugin via a [release](https://github.com/vapor-ware/synse-juniper-jti-plugin/releases)\nbinary or via Docker image\n\n```\ndocker pull vaporio/juniper-jti-plugin\n```\n\nIf you wish to use a development build, fork/clone the repo and build the plugin\nfrom source.\n\n### Running\n\nA [compose file](docker-compose.yaml) is included in this repo which provides a basic example of\nhow to run the Juniper JTI plugin in conjunction with Synse Server. You may also run the plugin  on\nits own\n\n```\ndocker run -d \\\n    --name juniper-jti \\\n    -p 5010:5010 \\\n    -p 5566:5566/udp \\\n    -v ./config.yaml:/etc/synse/plugin/config/config.yaml \\\n    vaporio/juniper-jti-plugin\n```\n\nand use the [Synse CLI](https://github.com/vapor-ware/synse-cli) to query the plugin's gRPC API.\n\nThe Juniper JTI plugin will run with minimal configuration (e.g. with config for the UDP server), but\nwill not provide any data unless JTI data is streamed to the exposed UDP server. As such, the example\ndeployment will run, but will not provide any useful data.\n\n## Juniper JTI Plugin Configuration\n\nPlugin and device configuration are described in detail in the [SDK Documentation](https://synse.readthedocs.io/en/latest/sdk/intro/).\n\nWhen deploying, you will need to provide your own plugin configuration (`config.yaml`)\nwith dynamic configuration defined. This is how the Juniper JTI plugin's UDP server is\nconfigured, allowing Juniper devices to stream telemetry data to it.\n\nAs an example:\n\n```yaml\ndynamicRegistration:\n  config:\n  - address: udp://0.0.0.0:5566\n    context:\n      site: ke1-test\n```\n\nNote that the IP address in this example is `0.0.0.0`. When running the plugin via a Docker\ncontainer, you will want to use this address so it is able to correctly capture the incoming packets.\n\n### Dynamic Registration Options\n\nBelow are the fields that are expected in each of the dynamic registration items.\nIf no default is specified (`-`), the field is required.\n\n| Field   | Description | Default |\n| ------- | ----------- | ------- |\n| address | The protocol/address/port for the UDP server to listen for incoming telemetry data. The protocol may be one of: [`udp`, `udp4`, `udp6`]. When running in a docker container, the address should be `0.0.0.0`. | `-` |\n| context | Additional key-value pairs to be globally applied to all device contexts for devices managed by a plugin instance. | `{}` |\n\n### Reading Outputs\n\nOutputs are referenced by name. A single device may have more than one instance\nof an output type. A value of `-` in the table below indicates that there is no value\nset for that field. The *custom* section describes outputs which this plugin defines\nwhile the *built-in* section describes outputs this plugin uses which are [built-in to\nthe SDK](https://synse.readthedocs.io/en/latest/sdk/concepts/reading_outputs/#built-ins).\n\n**Custom**\n\n| Name               | Description                                                                         | Unit    | Type         | Precision |\n| ------------------ | ----------------------------------------------------------------------------------- | :-----: | ------------ | :-------: |\n| boolean            | A true/false value.                                                                 | -       | `bool`       | -         |\n| bytes              | A count of bytes. This is not associated with any time scale.                       | bytes   | `counter`    | -         |\n| bytes-per-second   | The rate of bytes over a second.                                                    | bytes/s | `throughput` | -         |\n| decibel-milliwatt  | A measure of absolute power expressed as a ratio between decibels to one milliwatt. | dBm     | `power`      | -         |\n| megabit-per-second | The rate of 1,000,000 bits over a second.                                           | Mbit/s  | `throughput` | -         |\n| milliampere        | A measure of electric current, in thousandths of an Ampere.                         | mA      | `current`    | -         |\n| packets            | A count of packets. This is not associated with any time scale.                     | pkts    | `counter`    | -         |\n| packets-per-second | The rate of packets over a second.                                                  | pkts/s  | `throughput` | -         |\n| time-ticks         | A measure of time, described in \"time ticks\".                                       | ticks   | `time`       | -         |\n\n**Built-in**\n\n| Name          | Description                                   | Unit  | Type          | Precision |\n| ------------- | --------------------------------------------- | :---: | ------------- | :-------: |\n| number        | An arbitrary, unit-less number.               | -     | `number`      | 2         |\n| status        | A generic description of status.              | -     | `status`      | -         |\n| string        | A generic output for string data.             | -     | `string`      | -         |\n| temperature   | A measure of temperature, in degrees Celsius. | C     | `temperature` | 2         |\n| timestamp     | A string describing a timestamp.              | -     | `timestamp`   | -         |\n\n### Device Handlers\n\nDevice Handlers are referenced by name.\n\n| Name | Description                        | Outputs | Read  | Write | Bulk Read | Listen |\n| ---- | ---------------------------------- | ------- | :---: | :---: | :-------: | :----: |\n| jti  | A handler for all Juniper devices. | -       | ✓     | ✗     | ✗         | ✗      |\n\n### Write Values\n\nThis plugin does not support writing values to devices.\n\n## Compatibility\n\nBelow is a table describing the compatibility of plugin versions with Synse platform versions.\n\n|             | Synse v2 | Synse v3 |\n| ----------- | -------- | -------- |\n| plugin v0.x | ✗        | ✓        |\n\n## Troubleshooting\n\n### Debugging\n\nThe plugin can be run in debug mode for additional logging. This is done by:\n\n- Setting the `debug` option  to `true` in the plugin configuration YAML ([config.yml](example/config.yaml))\n\n  ```yaml\n  debug: true\n  ```\n\n- Passing the `--debug` flag when running the binary/image\n\n  ```\n  docker run vaporio/juniper-jti-plugin --debug\n  ```\n\n- Running the image with the `PLUGIN_DEBUG` environment variable set to `true`\n\n  ```\n  docker run -e PLUGIN_DEBUG=true vaporio/juniper-jti-plugin\n  ```\n\n### Developing\n\nA [development/debug Dockerfile](Dockerfile.dev) is provided in the project repository to enable\nbuilding image which may be useful when developing or debugging a plugin. Unlike the slim `scratch`-based\nproduction image, the development image uses an ubuntu base, bringing with it all the standard command line\ntools one would expect. To build a development image:\n\n```\nmake docker-dev\n```\n\nThe built image will be tagged using the format `dev-{COMMIT}`, where `COMMIT` is the short commit for\nthe repository at the time. This image is not published as part of the CI pipeline, but those with access\nto the Docker Hub repo may publish manually.\n\n## Contributing / Reporting\n\nIf you experience a bug, would like to ask a question, or request a feature, open a\n[new issue](https://github.com/vapor-ware/synse-juniper-jti-plugin/issues) and provide as much\ncontext as possible. All contributions, questions, and feedback are welcomed and appreciated.\n\n## For Developers\n\n### Notes on (re)compiling the .proto source files\n\nI either do not know enough about how `protoc` works, or am just otherwise struggling\nto get each source file to compile to a package correctly.\n\nAt present, running `$ ./scripts/gen_proto.sh` will generate the compiled Go source\nfor the proto files. The issue lies with the import paths.  The generated Go source\nis put into `pkg/protocol/jti/protos/{name}/{name}.pb.go`. All files (except\n`telemetry_top`) import `telemetry_top`, but the import is wrong as generated. As such,\nit needs to be updated from\n\n```go\nimport (\n\ttelemetry_top \"protos/telemetry_top\"\n)\n``` \n\nto\n\n```go\nimport (\n\ttelemetry_top \"github.com/vapor-ware/synse-juniper-jti-plugin/pkg/protocol/jti/protos/telemetry_top\"\n)\n``` \n\nNote also that the `.proto` files should have a `go_import` option added, e.g. for `port.proto`:\n\n```proto\noption go_package = \"protos/port\";\n```\n\n# License\n\nThe Synse Juniper JTI Plugin is licensed under GPLv3. See [LICENSE](LICENSE) for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvapor-ware%2Fsynse-juniper-jti-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvapor-ware%2Fsynse-juniper-jti-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvapor-ware%2Fsynse-juniper-jti-plugin/lists"}