Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update default port for OTLP exporter to 4317 #1516

Merged
merged 7 commits into from Jan 12, 2021
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Expand Up @@ -49,6 +49,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
([#1488](https://github.com/open-telemetry/opentelemetry-python/pull/1488))
- `opentelemetry-api` `opentelemety-sdk` Moved `idsgenerator` into sdk
([#1514](https://github.com/open-telemetry/opentelemetry-python/pull/1514))
- Update default port for OTLP exporter to 4317
srikanthccv marked this conversation as resolved.
Show resolved Hide resolved
([#1516](https://github.com/open-telemetry/opentelemetry-python/pull/1516))

## [0.16b1](https://github.com/open-telemetry/opentelemetry-python/releases/tag/v0.16b1) - 2020-11-26
### Added
Expand Down
Expand Up @@ -53,7 +53,7 @@
trace.set_tracer_provider(TracerProvider(resource=resource))
tracer = trace.get_tracer(__name__)

otlp_exporter = OTLPSpanExporter(endpoint="localhost:55680", insecure=True)
otlp_exporter = OTLPSpanExporter(endpoint="localhost:4317", insecure=True)

span_processor = BatchExportSpanProcessor(otlp_exporter)

Expand Down
Expand Up @@ -160,7 +160,7 @@ def __init__(
endpoint = (
endpoint
or Configuration().EXPORTER_OTLP_ENDPOINT
or "localhost:55680"
or "localhost:4317"
)

if insecure is None:
Expand Down
Expand Up @@ -70,7 +70,7 @@ def tearDown(self):
@patch.dict(
"os.environ",
{
"OTEL_EXPORTER_OTLP_METRIC_ENDPOINT": "collector:55680",
"OTEL_EXPORTER_OTLP_METRIC_ENDPOINT": "collector:4317",
"OTEL_EXPORTER_OTLP_METRIC_CERTIFICATE": THIS_DIR
+ "/fixtures/test.cert",
"OTEL_EXPORTER_OTLP_METRIC_HEADERS": "key1=value1,key2=value2",
Expand All @@ -84,7 +84,7 @@ def test_env_variables(self, mock_exporter_mixin):
self.assertTrue(len(mock_exporter_mixin.call_args_list) == 1)
_, kwargs = mock_exporter_mixin.call_args_list[0]

self.assertEqual(kwargs["endpoint"], "collector:55680")
self.assertEqual(kwargs["endpoint"], "collector:4317")
self.assertEqual(kwargs["headers"], "key1=value1,key2=value2")
self.assertEqual(kwargs["timeout"], 10)
self.assertIsNotNone(kwargs["credentials"])
Expand Down
Expand Up @@ -116,7 +116,7 @@ def setUp(self):

self.server = server(ThreadPoolExecutor(max_workers=10))

self.server.add_insecure_port("[::]:55680")
self.server.add_insecure_port("[::]:4317")

self.server.start()

Expand Down Expand Up @@ -169,7 +169,7 @@ def tearDown(self):
@patch.dict(
"os.environ",
{
"OTEL_EXPORTER_OTLP_SPAN_ENDPOINT": "collector:55680",
"OTEL_EXPORTER_OTLP_SPAN_ENDPOINT": "collector:4317",
"OTEL_EXPORTER_OTLP_SPAN_CERTIFICATE": THIS_DIR
+ "/fixtures/test.cert",
"OTEL_EXPORTER_OTLP_SPAN_HEADERS": "key1=value1,key2=value2",
Expand All @@ -183,7 +183,7 @@ def test_env_variables(self, mock_exporter_mixin):
self.assertTrue(len(mock_exporter_mixin.call_args_list) == 1)
_, kwargs = mock_exporter_mixin.call_args_list[0]

self.assertEqual(kwargs["endpoint"], "collector:55680")
self.assertEqual(kwargs["endpoint"], "collector:4317")
self.assertEqual(kwargs["headers"], "key1=value1,key2=value2")
self.assertEqual(kwargs["timeout"], 10)
self.assertIsNotNone(kwargs["credentials"])
Expand Down