Skip to content
This repository was archived by the owner on Jul 31, 2023. It is now read-only.

Commit 937fca0

Browse files
committed
update documentation to match new API
1 parent b9c0e9e commit 937fca0

30 files changed

+327
-1213
lines changed

doc/README.md

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -178,21 +178,16 @@ $ rebar3 protobuf compile
178178

179179

180180
<table width="100%" border="0" summary="list of modules">
181+
<tr><td><a href="oc_internal_timer.md" class="module">oc_internal_timer</a></td></tr>
181182
<tr><td><a href="oc_producer.md" class="module">oc_producer</a></td></tr>
182183
<tr><td><a href="oc_producer_registry.md" class="module">oc_producer_registry</a></td></tr>
183-
<tr><td><a href="oc_reporter.md" class="module">oc_reporter</a></td></tr>
184-
<tr><td><a href="oc_reporter_noop.md" class="module">oc_reporter_noop</a></td></tr>
185-
<tr><td><a href="oc_reporter_sequential.md" class="module">oc_reporter_sequential</a></td></tr>
186-
<tr><td><a href="oc_reporter_stdout.md" class="module">oc_reporter_stdout</a></td></tr>
187-
<tr><td><a href="oc_reporter_zipkin.md" class="module">oc_reporter_zipkin</a></td></tr>
188184
<tr><td><a href="oc_sampler.md" class="module">oc_sampler</a></td></tr>
189185
<tr><td><a href="oc_sampler_always.md" class="module">oc_sampler_always</a></td></tr>
190186
<tr><td><a href="oc_sampler_impl.md" class="module">oc_sampler_impl</a></td></tr>
191187
<tr><td><a href="oc_sampler_never.md" class="module">oc_sampler_never</a></td></tr>
192188
<tr><td><a href="oc_sampler_period_or_count.md" class="module">oc_sampler_period_or_count</a></td></tr>
193189
<tr><td><a href="oc_sampler_probability.md" class="module">oc_sampler_probability</a></td></tr>
194190
<tr><td><a href="oc_self_producer.md" class="module">oc_self_producer</a></td></tr>
195-
<tr><td><a href="oc_server.md" class="module">oc_server</a></td></tr>
196191
<tr><td><a href="oc_span.md" class="module">oc_span</a></td></tr>
197192
<tr><td><a href="oc_span_ctx_binary.md" class="module">oc_span_ctx_binary</a></td></tr>
198193
<tr><td><a href="oc_span_ctx_header.md" class="module">oc_span_ctx_header</a></td></tr>
@@ -204,20 +199,19 @@ $ rebar3 protobuf compile
204199
<tr><td><a href="oc_stat_aggregation_distribution.md" class="module">oc_stat_aggregation_distribution</a></td></tr>
205200
<tr><td><a href="oc_stat_aggregation_latest.md" class="module">oc_stat_aggregation_latest</a></td></tr>
206201
<tr><td><a href="oc_stat_aggregation_sum.md" class="module">oc_stat_aggregation_sum</a></td></tr>
207-
<tr><td><a href="oc_stat_config.md" class="module">oc_stat_config</a></td></tr>
208-
<tr><td><a href="oc_stat_exporter.md" class="module">oc_stat_exporter</a></td></tr>
209-
<tr><td><a href="oc_stat_exporter_stdout.md" class="module">oc_stat_exporter_stdout</a></td></tr>
210202
<tr><td><a href="oc_stat_measure.md" class="module">oc_stat_measure</a></td></tr>
203+
<tr><td><a href="oc_stat_reporter.md" class="module">oc_stat_reporter</a></td></tr>
204+
<tr><td><a href="oc_stat_stdout_handler.md" class="module">oc_stat_stdout_handler</a></td></tr>
211205
<tr><td><a href="oc_stat_transform.md" class="module">oc_stat_transform</a></td></tr>
212206
<tr><td><a href="oc_stat_unit.md" class="module">oc_stat_unit</a></td></tr>
213207
<tr><td><a href="oc_stat_view.md" class="module">oc_stat_view</a></td></tr>
214-
<tr><td><a href="oc_std_encoder.md" class="module">oc_std_encoder</a></td></tr>
215208
<tr><td><a href="oc_tag_ctx_binary.md" class="module">oc_tag_ctx_binary</a></td></tr>
216209
<tr><td><a href="oc_tag_ctx_header.md" class="module">oc_tag_ctx_header</a></td></tr>
217210
<tr><td><a href="oc_tags.md" class="module">oc_tags</a></td></tr>
218211
<tr><td><a href="oc_trace.md" class="module">oc_trace</a></td></tr>
212+
<tr><td><a href="oc_trace_reporter.md" class="module">oc_trace_reporter</a></td></tr>
213+
<tr><td><a href="oc_trace_stdout_handler.md" class="module">oc_trace_stdout_handler</a></td></tr>
219214
<tr><td><a href="ocp.md" class="module">ocp</a></td></tr>
220215
<tr><td><a href="opencensus.md" class="module">opencensus</a></td></tr>
221-
<tr><td><a href="opencensus_app.md" class="module">opencensus_app</a></td></tr>
222-
<tr><td><a href="opencensus_sup.md" class="module">opencensus_sup</a></td></tr></table>
216+
<tr><td><a href="opencensus_app.md" class="module">opencensus_app</a></td></tr></table>
223217

doc/build.sh

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
11
#!/bin/bash
22

3-
cd $(dirname $(realpath $0))
3+
cd "$(dirname $(realpath $0))"
44

55
cp ../README.md index.md
66

77
make clean
88
make
99

1010
# fix internal doc links
11-
sed -i 's/https:\/\/github\.com\/doc\/\(.*\)\.md/\1.html/g' *.html
12-
sed -i 's/\"\([a-zA-Z_-]*\)\.md\([a-zA-Z_-#]*\)\"/\"\1.html\2\"/g' *.html
13-
sed -i 's/\"doc\/\([a-zA-Z_-]*\)\.md\"/\"\1.html\"/g' *.html
14-
sed -i 's/\"\([a-zA-Z_-]*\)\.md\"/\"\1.html\"/g' *.html
15-
sed -i 's/<br \/>//g' *.html
11+
sed -i '' 's/https:\/\/github\.com\/doc\/\(.*\)\.md/\1.html/g' *.html
12+
sed -i '' 's/\"\([a-zA-Z_-]*\)\.md\([a-zA-Z_#-]*\)\"/\"\1.html\2\"/g' *.html
13+
sed -i '' 's/\"doc\/\([a-zA-Z_-]*\)\.md\"/\"\1.html\"/g' *.html
14+
sed -i '' 's/\"\([a-zA-Z_-]*\)\.md\"/\"\1.html\"/g' *.html
15+
sed -i '' 's/<br \/>//g' *.html
1616

1717
# sed -i 's/\"\(.*\)\.md\"/\"\1.html\"/g' *.html
1818
# sed -i 's/\"\(.*\)\.md#\(.*\)\"/\"\1.html#\2\"/g' *.html
1919

2020
# fix external doc links
21-
sed -i 's/maps\.html\#/http:\/\/erlang.org\/doc\/man\/maps\.html#/g' *.html
22-
sed -i 's/unicode\.html\#/http:\/\/erlang.org\/doc\/man\/unicode\.html#/g' *.html
23-
sed -i 's/maps\.md\#/http:\/\/erlang.org\/doc\/man\/maps\.html#/g' *.html
24-
sed -i 's/unicode\.md\#/http:\/\/erlang.org\/doc\/man\/unicode\.html#/g' *.html
21+
sed -i '' 's/maps\.html\#/http:\/\/erlang.org\/doc\/man\/maps\.html#/g' *.html
22+
sed -i '' 's/unicode\.html\#/http:\/\/erlang.org\/doc\/man\/unicode\.html#/g' *.html
23+
sed -i '' 's/maps\.md\#/http:\/\/erlang.org\/doc\/man\/maps\.html#/g' *.html
24+
sed -i '' 's/unicode\.md\#/http:\/\/erlang.org\/doc\/man\/unicode\.html#/g' *.html
2525

2626
# cleans up the indentation of code blocks
27-
sed -i 's/ <a/<a/g' index.html
27+
sed -i '' 's/ <a/<a/g' index.html

doc/edoc-info

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
%% encoding: UTF-8
22
{application,opencensus}.
3-
{modules,[oc_producer,oc_producer_registry,oc_reporter,oc_reporter_noop,
4-
oc_reporter_sequential,oc_reporter_stdout,oc_reporter_zipkin,
5-
oc_sampler,oc_sampler_always,oc_sampler_impl,oc_sampler_never,
3+
{modules,[oc_internal_timer,oc_producer,oc_producer_registry,oc_sampler,
4+
oc_sampler_always,oc_sampler_impl,oc_sampler_never,
65
oc_sampler_period_or_count,oc_sampler_probability,oc_self_producer,
7-
oc_server,oc_span,oc_span_ctx_binary,oc_span_ctx_header,
8-
oc_span_sweeper,oc_span_transform,oc_stat,oc_stat_aggregation,
6+
oc_span,oc_span_ctx_binary,oc_span_ctx_header,oc_span_sweeper,
7+
oc_span_transform,oc_stat,oc_stat_aggregation,
98
oc_stat_aggregation_count,oc_stat_aggregation_distribution,
10-
oc_stat_aggregation_latest,oc_stat_aggregation_sum,oc_stat_config,
11-
oc_stat_exporter,oc_stat_exporter_stdout,oc_stat_measure,
12-
oc_stat_transform,oc_stat_unit,oc_stat_view,oc_std_encoder,
13-
oc_tag_ctx_binary,oc_tag_ctx_header,oc_tags,oc_trace,ocp,opencensus,
14-
opencensus_app,opencensus_sup]}.
9+
oc_stat_aggregation_latest,oc_stat_aggregation_sum,oc_stat_measure,
10+
oc_stat_reporter,oc_stat_stdout_handler,oc_stat_transform,
11+
oc_stat_unit,oc_stat_view,oc_tag_ctx_binary,oc_tag_ctx_header,
12+
oc_tags,oc_trace,oc_trace_reporter,oc_trace_stdout_handler,ocp,
13+
opencensus,opencensus_app]}.

doc/index.md

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,11 @@ Headers = [{oc_span_ctx_header:field_name(), EncodedSpanCtx}],
7676

7777
#### <a name="Reporters">Reporters</a> ####
7878

79-
[Google Cloud Trace](https://github.com/tsloughter/oc_google_reporter): Support for v1 in master, v2 and grpc coming soon;
79+
[Zipkin](https://github.com/opencensus-beam/opencensus_zipkin): Zipkin v2 reporter.
8080

81-
[Prometheus](https://github.com/deadtrickster/opencensus-erlang-prometheus): Exports spans as Prometheus metrics.
81+
[Google Cloud Trace](https://github.com/opencensus-beam/oc_google_reporter): Support for v1 in master, v2 and grpc coming soon;
82+
83+
[Prometheus](https://github.com/opencensus-beam/prometheus): Exports spans as Prometheus metrics.
8284

8385
[DataDog][oc_datadog]: Export spans to DataDog APM
8486

@@ -185,13 +187,4 @@ Running tests:
185187
$ rebar3 ct
186188
```
187189

188-
#### Updating OpenCensus standard protobuf encoder and decoder
189-
190-
Language independent interface types for Census are found in the `opencensus-proto` repo. The opencensus Erlang app provides functionality for converting from the apps internal representation to the standard protobuf interface. Below are the steps to update the Erlang module and header for encoding and decoding the protobufs:
191-
192-
```sh
193-
$ git clone https://github.com/census-instrumentation/opencensus-proto priv/opencensus-proto
194-
$ rebar3 protobuf compile
195-
```
196-
197190
[oc_datadog]: https://github.com/hauleth/oc_datadog

doc/oc_internal_timer.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
2+
3+
# Module oc_internal_timer #
4+
* [Function Index](#index)
5+
* [Function Details](#functions)
6+
7+
__This module defines the `oc_internal_timer` behaviour.__<br /> Required callback functions: `ping/0`.
8+
9+
<a name="index"></a>
10+
11+
## Function Index ##
12+
13+
14+
<table width="100%" border="1" cellspacing="0" cellpadding="2" summary="function index"><tr><td valign="top"><a href="#handle_call-3">handle_call/3</a></td><td></td></tr><tr><td valign="top"><a href="#handle_cast-2">handle_cast/2</a></td><td></td></tr><tr><td valign="top"><a href="#handle_info-2">handle_info/2</a></td><td></td></tr><tr><td valign="top"><a href="#init-1">init/1</a></td><td></td></tr><tr><td valign="top"><a href="#start_link-2">start_link/2</a></td><td></td></tr></table>
15+
16+
17+
<a name="functions"></a>
18+
19+
## Function Details ##
20+
21+
<a name="handle_call-3"></a>
22+
23+
### handle_call/3 ###
24+
25+
`handle_call(Msg, From, State) -> any()`
26+
27+
<a name="handle_cast-2"></a>
28+
29+
### handle_cast/2 ###
30+
31+
`handle_cast(Msg, State) -> any()`
32+
33+
<a name="handle_info-2"></a>
34+
35+
### handle_info/2 ###
36+
37+
`handle_info(X1, State) -> any()`
38+
39+
<a name="init-1"></a>
40+
41+
### init/1 ###
42+
43+
`init(X1) -> any()`
44+
45+
<a name="start_link-2"></a>
46+
47+
### start_link/2 ###
48+
49+
`start_link(Interval, Module) -> any()`
50+

doc/oc_reporter.md

Lines changed: 0 additions & 77 deletions
This file was deleted.

doc/oc_reporter_noop.md

Lines changed: 0 additions & 35 deletions
This file was deleted.

doc/oc_reporter_sequential.md

Lines changed: 0 additions & 74 deletions
This file was deleted.

0 commit comments

Comments
 (0)