question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support transaction finishing automatically with 'idle timeout'

See original GitHub issue

The goal is to have a mode for finishing transactions automatically once no new spans are added to it for N milliseconds, or a general timeout.

We need to define the spec in the develop.sentry.dev docs and align with other implementations of it. This is an approach used by the JS on the browser (and React Native).

Note On Android: we introduced an opt-out for the auto activity transaction from closing on rendering (it should only add/end span instead of the whole transaction). In that case might not use the idle timeout transaction when that flag is opt-in and rely on the user programatic finish call instead.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
marandanetocommented, Jun 16, 2021

with the waitForChildren feat, io.sentry.traces.activity.auto-finish.enable will likely get deprecated, I don’t see a reason why having it anymore. https://docs.sentry.io/platforms/android/performance/instrumentation/automatic-instrumentation/

0reactions
rhcarvalhocommented, Jun 22, 2021

We may also consider how this special transaction will behave as we focus more on spans, and one day be able to ingest data without buffering full transactions in memory.

Perhaps, if we make the functionality of “automatically finish” available to any span, that would put us in a better future position, not tied to transactions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support transaction finishing automatically with 'idle timeout'
The idea is to have transactions that do not have a specified ending but a timeout instead. As if we had a mode...
Read more >
idle_in_transaction_session_tim...
Long PostgreSQL transactions can cause table bloat. idle_in_transaction_session_timeout offers way to limit the duration of a transaction to ...
Read more >
How to close idle connections in PostgreSQL automatically?
This will only close connections that opened a transaction and failed to close (commit or rollback) it within the given timeout (as the...
Read more >
UI Event Transactions - Sentry Developer Documentation
Idle-transactions: The SDK schedule an idle timeout for the transaction when starting it. When the transaction or any of its spans starts a...
Read more >
Ending Idle Transactions - 华为云
If an idle transaction is not committed for a long time, its rollback will consume database resources and performance.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found