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

Batch exporter doesn't work with children of forked processes #1567

Closed
jpmelos opened this issue Feb 2, 2021 · 3 comments
Closed

Batch exporter doesn't work with children of forked processes #1567

jpmelos opened this issue Feb 2, 2021 · 3 comments
Labels
backlog bug Something isn't working

Comments

@jpmelos
Copy link

jpmelos commented Feb 2, 2021

Describe your environment
Python 3.6.9
python-opentelemetry 0.16b1

Steps to reproduce
Instrument your app using the batch exporter as a span processor:

    trace.get_tracer_provider().add_span_processor(
        BatchExportSpanProcessor(
            jaeger.JaegerSpanExporter(
                service_name=app.config['DEPLOYMENT_NAME'] or 'other',
                agent_host_name=jaeger_agent_host,
                agent_port=jaeger_agent_port,
            ),
            max_export_batch_size=SPAN_BATCH_MAX_SIZE,
        )
    )

Then, fork the process.

What is the expected behavior?
Sending traces and spans from the children of a forked process would work.

What is the actual behavior?
The child process can't send traces and spans.

@jpmelos jpmelos added the bug Something isn't working label Feb 2, 2021
@srikanthccv
Copy link
Member

@jpmelos this is kind of limitation; You need to use fork hooks such as uWSGI uwsgidecorators.postfork, Gunicorn post_fork and os.register_at_fork.

@github-actions
Copy link

github-actions bot commented Apr 9, 2021

This issue was marked stale due to lack of activity. It will be closed in 30 days.

@github-actions
Copy link

github-actions bot commented Jun 8, 2021

Closed as inactive. Feel free to reopen if this issue needs resolving.

@github-actions github-actions bot closed this as completed Jun 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants