Skip to content

Transaction listener is not called properly with nested transactions #539

Closed

Description

@oleksandr-semenov

Expected Behavior

When using nested transactions listener is called each time when the outer or inner transaction starts and ends/rolls back

Actual Behavior

The listener is not called in an expected way

Steps to Reproduce

Launch code with the nested transaction and observe the behavior
sqlcipher/sqlcipher-android-tests#39

SQLCipher version (can be identified by executing PRAGMA cipher_version;):
4.4.2 community

SQLCipher for Android version:
4.4.2

Note:
AndroidX SQLite database works as expected and dispatches all callbacks for nested and outer transactions.

Activity

  1. oleksandr-semenov commented on Mar 3, 2021

    @oleksandr-semenov
    Author
  2. developernotes commented on Mar 3, 2021

    @developernotes
    Member

    Hello @oleksandr-semenov

    Unfortunately, the current Java implementation used within SQLCipher for Android does not allow nesting SQLiteTransactionListener instances (i.e., it only allows for tracking a single listener, however, nested transactions are allowed). The current Google implementation of android.database.sqlite appears to support this via embedding the listener into a transaction object managed via a session connection pool. This may be something we revisit in a future release.

    We will leave this ticket open for for review and further discussion in the future.

  3. stale commented on Jun 3, 2021

    @stale

    Hello, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as "bug", "enhancement", or "security" and I will leave it open. Thank you for your contributions.

  4. added
    staleThis issue lacks recent activity.
    on Jun 3, 2021
  5. stale commented on Jun 23, 2021

    @stale

    Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to reopen with up-to-date information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleThis issue lacks recent activity.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions