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

[Core] Deprecate OpenCensus tracing plugin #37975

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions eng/.docsettings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ known_content_issues:
- ['sdk/core/azure-common/README.rst', 'common']
- ['sdk/core/azure-core/README.md', 'common']
- ['sdk/core/azure-core/samples/README.md', 'common']
- ['sdk/core/azure-core-tracing-opencensus/README.md', 'common']
- ['sdk/core/azure-core-tracing-opentelemetry/README.md', 'common']
- ['sdk/core/corehttp/README.md', 'common']
- ['sdk/core/corehttp/samples/README.md', 'common']
Expand Down
10 changes: 3 additions & 7 deletions sdk/core/azure-core-tracing-opencensus/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
# Release History

## 1.0.0b10 (Unreleased)

### Features Added

### Breaking Changes

### Bugs Fixed
## 1.0.0b10 (2024-11-05)

### Other Changes

- This package has been deprecated and will no longer be maintained after 11-05-2024. Use the [azure-core-tracing-opentelemetry](https://pypi.org/project/azure-core-tracing-opentelemetry/) package for tracing support in Azure SDK libraries.

## 1.0.0b9 (2023-05-09)

### Bugs Fixed
Expand Down
60 changes: 2 additions & 58 deletions sdk/core/azure-core-tracing-opencensus/README.md
Original file line number Diff line number Diff line change
@@ -1,61 +1,5 @@


# Azure Core Tracing OpenCensus client library for Python

## Getting started

Install the opencensus python for Python with [pip](https://pypi.org/project/pip/):

```bash
pip install azure-core-tracing-opencensus --pre
```

Now you can use opencensus for Python as usual with any SDKs that is compatible
with azure-core tracing. This includes (not exhaustive list), azure-storage-blob, azure-keyvault-secrets, azure-eventhub, etc.

## Key concepts

* You don't need to pass any context, SDK will get it for you
* The opencensus threading plugin is installed with this package

## Examples

There is no explicit context to pass, you just create your usual opencensus and tracer and
call any SDK code that is compatible with azure-core tracing. This is an example
using Azure Monitor exporter, but you can use any exporter (Zipkin, etc.).

```python
from opencensus.ext.azure.trace_exporter import AzureExporter

from opencensus.trace.tracer import Tracer
from opencensus.trace.samplers import AlwaysOnSampler

from azure.storage.blob import BlobServiceClient

exporter = AzureExporter(
instrumentation_key="uuid of the instrumentation key (see your Azure Monitor account)"
)

tracer = Tracer(exporter=exporter, sampler=AlwaysOnSampler())
with tracer.span(name="MyApplication") as span:
client = BlobServiceClient.from_connection_string('connectionstring')
client.delete_container('my_container') # Call will be traced
```


## Troubleshooting

This client raises exceptions defined in [Azure Core](https://docs.microsoft.com/python/api/azure-core/azure.core.exceptions?view=azure-python).


## Next steps

More documentation on OpenCensus configuration can be found on the [OpenCensus website](https://opencensus.io)


## Contributing
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This package has been deprecated and will no longer be maintained after 11-05-2024.

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [[email protected]](mailto:[email protected]) with any additional questions or comments.
Please use the [Azure Core Tracing OpenTelemetry](https://pypi.org/project/azure-core-tracing-opentelemetry/) package for tracing support in Azure SDK libraries.
2 changes: 1 addition & 1 deletion sdk/core/azure-core-tracing-opencensus/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
url="https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/core/azure-core-tracing-opencensus",
keywords="azure, azure sdk",
classifiers=[
"Development Status :: 4 - Beta",
"Development Status :: 7 - Inactive",
"Programming Language :: Python",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3",
Expand Down