• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..--

gen-go/25-Apr-2025-7,5905,923

gen-openapi/opencensus/proto/agent/25-Apr-2025-1,3041,302

gen-python/25-Apr-2025-4,2283,544

gen-ruby/opencensus/proto/25-Apr-2025-647537

gradle/wrapper/25-Apr-2025-65

src/25-Apr-2025-2,0141,605

AUTHORSD25-Apr-202511 11

CONTRIBUTING.mdD25-Apr-2025905 2717

LICENSED25-Apr-202511.1 KiB203169

README.mdD25-Apr-20253.1 KiB9378

RELEASING.mdD25-Apr-20258.9 KiB263195

build.gradleD25-Apr-20254.9 KiB173143

gradlewD25-Apr-20255.2 KiB173128

gradlew.batD25-Apr-20252.2 KiB8561

settings.gradleD25-Apr-202538 21

README.md

1OpenCensus Proto - Language Independent Interface Types For OpenCensus
2===============================================================
3[![Gitter chat][gitter-image]][gitter-url]
4[![Build Status][travis-image]][travis-url]
5[![Maven Central][maven-image]][maven-url]
6[![Javadocs][javadoc-image]][javadoc-url]
7[![GoDoc][godoc-image]][godoc-url]
8[![PyPI][pypi-image]][pypi-url]
9
10Census provides a framework to define and collect stats against metrics and to
11break those stats down across user-defined dimensions.
12
13The Census framework is natively available in many languages (e.g. C++, Go,
14and Java). The API interface types are defined using protos to ensure
15consistency and interoperability for the different implementations.
16
17## Quickstart
18
19### Install to Go
20
21```bash
22$ go get -u github.com/census-instrumentation/opencensus-proto
23```
24
25In most cases you should depend on the gen-go files directly. If you are
26building with Bazel, there are also go_proto_library build rules available.
27See [PR/132](https://github.com/census-instrumentation/opencensus-proto/pull/132)
28for details. However, please note that Bazel doesn't generate the final
29artifacts.
30
31### Add the dependencies to your Java project
32
33For Maven add to `pom.xml`:
34```xml
35<dependency>
36  <groupId>io.opencensus</groupId>
37  <artifactId>opencensus-proto</artifactId>
38  <version>0.2.0</version>
39</dependency>
40```
41
42For Gradle add to dependencies:
43```gradle
44compile 'io.opencensus:opencensus-proto:0.2.0'
45```
46
47[travis-image]: https://travis-ci.org/census-instrumentation/opencensus-proto.svg?branch=master
48[travis-url]: https://travis-ci.org/census-instrumentation/opencensus-proto
49[maven-image]: https://maven-badges.herokuapp.com/maven-central/io.opencensus/opencensus-proto/badge.svg
50[maven-url]: https://maven-badges.herokuapp.com/maven-central/io.opencensus/opencensus-proto
51[gitter-image]: https://badges.gitter.im/census-instrumentation/lobby.svg
52[gitter-url]: https://gitter.im/census-instrumentation/lobby
53[javadoc-image]: https://www.javadoc.io/badge/io.opencensus/opencensus-proto.svg
54[javadoc-url]: https://www.javadoc.io/doc/io.opencensus/opencensus-proto
55[godoc-image]: https://godoc.org/github.com/census-instrumentation/opencensus-proto?status.svg
56[godoc-url]: https://godoc.org/github.com/census-instrumentation/opencensus-proto
57[pypi-image]: https://badge.fury.io/py/opencensus-proto.svg
58[pypi-url]: https://pypi.org/project/opencensus-proto/
59
60### Add the dependencies to Bazel project
61
62In WORKSPACE, add:
63```
64git_repository(
65    name = "io_opencensus_proto",
66    strip_prefix = "src",
67    tag = "v0.2.0", # CURRENT_OPENCENSUS_PROTO_VERSION
68    remote = "https://github.com/census-instrumentation/opencensus-proto",
69)
70```
71or
72
73```
74http_archive(
75    name = "io_opencensus_proto",
76    strip_prefix = "opencensus-proto-master/src",
77    urls = ["https://github.com/census-instrumentation/opencensus-proto/archive/master.zip"],
78)
79```
80
81In BUILD.bazel:
82```bazel
83proto_library(
84    name = "foo_proto",
85    srcs = ["foo.proto"],
86    deps = [
87      "@io_opencensus_proto//opencensus/proto/metrics/v1:metrics_proto",
88      "@io_opencensus_proto//opencensus/proto/trace/v1:trace_proto",
89      # etc.
90    ],
91)
92```
93