Skip to content

Commit

Permalink
Merge pull request #8 from agoda-com/readme-update
Browse files Browse the repository at this point in the history
Update README.md
  • Loading branch information
amitash-anand authored Jul 5, 2021
2 parents 9d74b05 + 64f0bb8 commit 0291260
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Designed to collect compile time metrics from developers local workstation and l
"branch": "master",
"type": ".Net",
"projectName": "Agoda.Cronos.Accommodation",
"repository": "git@github.agodadev.io:agoda-front-end/agoda-com-dictator.git",
"repository": "git@github.xxxx.io:front-end/dotnet-build-metrics.git",
"date": "2021-06-28T02:53:22.1420552Z"
}
```
Expand All @@ -28,11 +28,13 @@ To use the task simply add the `Agoda.Builds.Metrics` as a dependency to your pr
Condition="Exists('$(MSBuildThisFileDirectory)\..\packages\agoda.builds.metrics\1.0.6\build\Agoda.Builds.Metrics.targets')"
/>
```

ElasticSearch URL and the name of the index are taken from environment variables if they are present. The fallback values are http://backend-elasticsearch:9200 for the URL and build-metrics for the index. The index must already exist.
```
string uriString = !string.IsNullOrEmpty(Environment.GetEnvironmentVariable("url")) ? Environment.GetEnvironmentVariable("url") : "http://backend-elasticsearch:9200";
string index = !string.IsNullOrEmpty(Environment.GetEnvironmentVariable("index")) ? Environment.GetEnvironmentVariable("index") : "build-metrics";
```
Note that the version number is embedded in the path, if you upgrade the library you have to update all of the project files as well.

Grafana dashboard for data visualization:
http://grafana.agoda.local/d/bUtx5Zk7k/net-local-build-analysis?orgId=1&refresh=5s


Example in Visual Studio using MSBuild.
Expand Down

0 comments on commit 0291260

Please sign in to comment.