{"id":26057666,"url":"https://github.com/wavefronthq/wavefront-spring-boot","last_synced_at":"2025-03-08T11:58:15.824Z","repository":{"id":37898070,"uuid":"235918503","full_name":"wavefrontHQ/wavefront-spring-boot","owner":"wavefrontHQ","description":"Spring Boot starter for Wavefront","archived":false,"fork":false,"pushed_at":"2024-07-22T22:52:28.000Z","size":859,"stargazers_count":29,"open_issues_count":8,"forks_count":31,"subscribers_count":32,"default_branch":"springboot3","last_synced_at":"2024-07-23T02:27:34.995Z","etag":null,"topics":[],"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/wavefrontHQ.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-24T01:14:04.000Z","updated_at":"2024-07-22T22:52:24.000Z","dependencies_parsed_at":"2023-12-19T00:50:06.110Z","dependency_job_id":"a51032f6-2a5e-47ba-be10-965c917afe2f","html_url":"https://github.com/wavefrontHQ/wavefront-spring-boot","commit_stats":null,"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wavefrontHQ%2Fwavefront-spring-boot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wavefrontHQ%2Fwavefront-spring-boot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wavefrontHQ%2Fwavefront-spring-boot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wavefrontHQ%2Fwavefront-spring-boot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wavefrontHQ","download_url":"https://codeload.github.com/wavefrontHQ/wavefront-spring-boot/tar.gz/refs/heads/springboot3","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242546038,"owners_count":20147096,"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":[],"created_at":"2025-03-08T11:58:15.014Z","updated_at":"2025-03-08T11:58:15.812Z","avatar_url":"https://github.com/wavefrontHQ.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Wavefront for Spring Boot 3\n\n[![CI Status][ci-img]][ci] [![Released Version][maven-img]][maven]\n\nThis project provides a Spring Boot 3 starter for Wavefront. Add the starter to a project to send metrics, histograms, and traces to a Wavefront cluster. If you don't have a Wavefront account, the starter creates a freemium account for you and saves the API token in your home directory at `~/.wavefront_freemium`.\n\n\u003e **Note**: Spring Boot 2 users should refer to the [README](https://github.com/wavefrontHQ/wavefront-spring-boot/tree/master) on the `master` branch.\n\n## Table of Contents\n\n* [Prerequisites](#prerequisites)\n* [Getting Started](#getting-started)\n* [Building](#building)\n* [Documentation](#documentation)\n* [License](#license)\n* [Getting Support](#getting-support)\n\n## Prerequisites\n\n* Spring Boot 3.0 or above\n* Java 17 or above\n* Maven 3.5+ or Gradle 7.5+\\\n  See [System Requirements](https://docs.spring.io/spring-boot/docs/3.0.x/reference/html/getting-started.html#getting-started.system-requirements) in the Spring Boot documentation.\n\n\u003e **Note**: This starter reuses the existing Wavefront support for [Metrics](https://docs.spring.io/spring-boot/docs/3.0.x/reference/html/actuator.html#actuator.metrics.export.wavefront) and [Tracing](https://docs.spring.io/spring-boot/docs/3.0.x/reference/html/actuator.html#actuator.micrometer-tracing)\nin Spring Boot and provides the Actuator (i.e., `spring-boot-starter-actuator`).\n\n## Getting Started\n\nThere are several ways to start:\n\n### Create a New Project\n\nThe easiest way to get started is to:\n1. Create a new project on [start.spring.io](https://start.spring.io).\n1. Select Spring Boot `3.0.0` or later and define the other parameters for your project.\n1. Click \"Add dependency\" and select `Wavefront` from the dependency list. \n1. To include tracing support, add the `Distributed Tracing` dependency as well.\n\nIf you don't have a Wavefront account, the starter creates a freemium account for you and saves the API token in your home directory at `~/.wavefront_freemium`.\n\n### Update an Existing Application\n\nIf you already have a Spring Boot application, you can use [start.spring.io](https://start.spring.io) to explore a new project from your browser.\nThis allows you to see the setup for the Spring Boot generation your project is using.\n\nNext, follow the steps under [**Maven**](#maven-install) or [**Gradle**](#gradle-install) to add the Wavefront Spring Boot BOM.\n\n#### Maven \u003ca name=\"maven-install\"\u003e\u003c/a\u003e\n\nFollow these steps:\n\n1. Import the `wavefront-spring-boot-bom` Bill Of Materials (BOM):\n\n      ```\n      \u003cdependencyManagement\u003e\n        \u003cdependencies\u003e\n          \u003cdependency\u003e\n            \u003cgroupId\u003ecom.wavefront\u003c/groupId\u003e\n            \u003cartifactId\u003ewavefront-spring-boot-bom\u003c/artifactId\u003e\n            \u003cversion\u003e3.0.1\u003c/version\u003e\n            \u003ctype\u003epom\u003c/type\u003e\n            \u003cscope\u003eimport\u003c/scope\u003e\n          \u003c/dependency\u003e\n        \u003c/dependencies\u003e\n      \u003c/dependencyManagement\u003e\n      ```\n\n1. Add the `wavefront-spring-boot-starter` dependency to your project:\n\n      ```\n      \u003cdependency\u003e\n        \u003cgroupId\u003ecom.wavefront\u003c/groupId\u003e\n        \u003cartifactId\u003ewavefront-spring-boot-starter\u003c/artifactId\u003e\n      \u003c/dependency\u003e\n      ```\n\n#### Gradle \u003ca name=\"gradle-install\"\u003e\u003c/a\u003e\n\nFollow these steps:\n\n1. Make sure your project uses the `io.spring.dependency-management` plugin and add the following to your `build.gradle` file:\n\n    ```\n      dependencyManagement {\n        imports {\n          mavenBom \"com.wavefront:wavefront-spring-boot-bom:3.0.1\"\n        }\n      }\n    ```\n\n1. Add the `wavefront-spring-boot-starter` dependency to your project:\n\n    ```\n      dependencies {\n        ...\n        implementation 'com.wavefront:wavefront-spring-boot-starter'\n      }\n    ```\n\n#### Configure the Application and Service Names\n\nSet the Application and Service Name in `application.properties`. In Wavefront, the Application\nrepresents a logical grouping of individual Services. For example, a `shopping` application might be\ncomprised of the `cart` and `payment` services. If your Spring Boot app is the `payment` service:\n\n```\nmanagement.wavefront.application.name=shopping\nmanagement.wavefront.application.service-name=payment\n```\n\n\n---\nEach time you restart your application, it either creates a new freemium account, or it restores from `~/.wavefront_freemium`.\nAt the end of the startup phase, the console displays a message with a login URL.\nUse it to log in to the Wavefront service and access the data that has been collected so far.\n\nHere is an example message when an existing account is restored from `~/.wavefront_freemium`:\n\n```text\nYour existing Wavefront account information has been restored from disk.\nTo share this account, make sure the following is added to your configuration:\n\n  management.wavefront.api-token=2c96d63a-abcd-efgh-ijhk-841611451e07\n  management.wavefront.uri=https://wavefront.surf\n\nConnect to your Wavefront dashboard using this one-time use link:\nhttps://wavefront.surf/us/example\n```\n\n## Tracing Support\n\nIf you'd like to send traces to Wavefront, you can do so using [Micrometer Tracing](https://micrometer.io/docs/tracing). Follow these steps:\n\n1. Choose a Micrometer Tracer for your usecase. For instructions, see [Micrometer's Supported Tracer documentation](https://micrometer.io/docs/tracing#_supported_tracers). For example, to use the OpenTelemetry Tracer:\n\n   - **Maven**: Add the following dependency to the `pom.xml` file:\n\n     ```\n     \u003cdependency\u003e\n       \u003cgroupId\u003eio.micrometer\u003c/groupId\u003e\n       \u003cartifactId\u003emicrometer-tracing-bridge-otel\u003c/artifactId\u003e\n     \u003c/dependency\u003e\n     ```\n\n   - **Gradle**: Add the following dependency to the `build.gradle` file:\n\n     ```\n     dependencies {\n       ...\n       implementation 'io.micrometer:micrometer-tracing-bridge-otel'\n     }\n     ```\n     \n1. For demo purposes, configure distributed tracing sampling to 100% in `application.properties`:\n\n   ```\n   management.tracing.sampling.probability=1.0\n   ```\n\n## Building\nTo build the latest state of this project, invoke the following command from the root directory:\n\n```shell script\n$ ./mvnw clean install\n```\n\nThe project has a sample that showcases the basic usage of the starter.\nIt starts a web app on `localhost:8080`.\nInvoke the following command from the root directory:\n\n```shell script\n$ ./mvnw spring-boot:run -pl wavefront-spring-boot-sample\n```\n\n## Documentation\n\n* The [Wavefront documentation](https://docs.wavefront.com/wavefront_springboot3.html) includes a tutorial and instructions for examining services and traces inside Wavefront.\n* You can [customize existing Spring Boot applications](https://docs.wavefront.com/wavefront_springboot3.html#custom-configurations) to send data to Wavefront.\n\n## License\n\n[Open Source License](open_source_licenses.txt)\n\n## Getting Support\n\n* If you run into any issues, let us know by creating a GitHub issue.\n* If you didn't find the information you are looking for in our [Wavefront Documentation](https://docs.wavefront.com/) create a GitHub issue or PR in our [docs repository](https://github.com/wavefrontHQ/docs).\n\n[ci-img]: https://github.com/wavefrontHQ/wavefront-spring-boot/actions/workflows/maven.yml/badge.svg?branch=springboot3\n[ci]: https://github.com/wavefrontHQ/wavefront-spring-boot/actions/workflows/maven.yml?query=branch%3aspringboot3\n[maven-img]: https://img.shields.io/maven-central/v/com.wavefront/wavefront-spring-boot.svg?maxAge=604800\n[maven]: https://search.maven.org/search?q=wavefront-spring-boot\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwavefronthq%2Fwavefront-spring-boot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwavefronthq%2Fwavefront-spring-boot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwavefronthq%2Fwavefront-spring-boot/lists"}