Fixed
Status Update
Comments
[Deleted User] <[Deleted User]> #2
Is there any hope that this will be looked at any time soon?
I find it pretty disappointing that there is no way to debug queries. I am using Room in an application with foreign key relationships, and these are failing silently and for some mysterious reason, and I have no way to debug my queries other than manually adding a bunch of LogCat logs.
Thank you for considering this.
I find it pretty disappointing that there is no way to debug queries. I am using Room in an application with foreign key relationships, and these are failing silently and for some mysterious reason, and I have no way to debug my queries other than manually adding a bunch of LogCat logs.
Thank you for considering this.
ab...@gmail.com <ab...@gmail.com> #3
Hello
Room database looks very promising and interesting, But I am still on initial stage of learning it and I am facing the problem of not being able to see log outputs of the database.
While implementing / learning debugging should be enabled.
It would be extremely helpful if we can have debugging logs for Room database implementation.
Thanks and regards
Abhiroop Nandi Ray
Room database looks very promising and interesting, But I am still on initial stage of learning it and I am facing the problem of not being able to see log outputs of the database.
While implementing / learning debugging should be enabled.
It would be extremely helpful if we can have debugging logs for Room database implementation.
Thanks and regards
Abhiroop Nandi Ray
yb...@google.com <yb...@google.com> #4
sorry, we are not agianst this feature but it is just not a high priority right now.
You can technically implement this outside room by providing your logging support sqlite open helper.
you can also consider sending a CL ? :)
https://android.googlesource.com/platform/frameworks/support/+/androidx-master-dev
You can technically implement this outside room by providing your logging support sqlite open helper.
you can also consider sending a CL ? :)
ko...@gmail.com <ko...@gmail.com> #5
te...@gmail.com <te...@gmail.com> #6
sy...@gmail.com <sy...@gmail.com> #7
This is needed for asserting query execution and increasing the speed of adoption of the framework. Please prioritize higher as simple as it is.
da...@gmail.com <da...@gmail.com> #8
Please, it would be very helpful for developers to be able to debug room operations in an easy way.
mi...@pharos-solutions.de <mi...@pharos-solutions.de> #9
Please, it would be very helpful for a more complicated erd, prioritize higher as soon as possible.
yb...@google.com <yb...@google.com> #10
this looks like a perfect candidate for external contribution.
It is also probably better to implement this in the androidx.sqlite package instead to ensure all queries are covered.
el...@google.com <el...@google.com>
ap...@google.com <ap...@google.com> #11
Project: platform/frameworks/support
Branch: androidx-master-dev
commit ab6d205c0217a0ed5c170bf6ceadb20422947699
Author: Elif Bilgin <elifbilgin@google.com>
Date: Tue Nov 17 13:50:26 2020
Implementing functionality for a general callback function for SQLite queries. If possible, bind arguments are provided to the callback in addition to the SQLite query statement. This callback may be used for logging executed queries, in which case it is recommended to use an immediate executor.
This CL will be followed up by a CL resolving b/174478034 .
Test: Tests have been added QueryInterceptorTest.kt
Relnote: Add query callback feature to Room.
Bug: 74877608
Change-Id: Iaa513e39115f0c9c68359774fa70e1d3dd022c39
A room/integration-tests/kotlintestapp/src/androidTest/java/androidx/room/integration/kotlintestapp/test/QueryInterceptorTest.kt
M room/runtime/api/current.txt
M room/runtime/api/public_plus_experimental_current.txt
M room/runtime/api/restricted_current.txt
A room/runtime/src/main/java/androidx/room/QueryInterceptorDatabase.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorOpenHelper.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorOpenHelperFactory.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorStatement.java
M room/runtime/src/main/java/androidx/room/RoomDatabase.java
https://android-review.googlesource.com/1502194
Branch: androidx-master-dev
commit ab6d205c0217a0ed5c170bf6ceadb20422947699
Author: Elif Bilgin <elifbilgin@google.com>
Date: Tue Nov 17 13:50:26 2020
Implementing functionality for a general callback function for SQLite queries. If possible, bind arguments are provided to the callback in addition to the SQLite query statement. This callback may be used for logging executed queries, in which case it is recommended to use an immediate executor.
This CL will be followed up by a CL resolving
Test: Tests have been added QueryInterceptorTest.kt
Relnote: Add query callback feature to Room.
Bug: 74877608
Change-Id: Iaa513e39115f0c9c68359774fa70e1d3dd022c39
A room/integration-tests/kotlintestapp/src/androidTest/java/androidx/room/integration/kotlintestapp/test/QueryInterceptorTest.kt
M room/runtime/api/current.txt
M room/runtime/api/public_plus_experimental_current.txt
M room/runtime/api/restricted_current.txt
A room/runtime/src/main/java/androidx/room/QueryInterceptorDatabase.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorOpenHelper.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorOpenHelperFactory.java
A room/runtime/src/main/java/androidx/room/QueryInterceptorStatement.java
M room/runtime/src/main/java/androidx/room/RoomDatabase.java
Description
Version used: 1.1.0-alpha3
Currently there is no built-in way to debug failed queries and there isn't much information logged in LogCat by Room either.
It would be extremely helpful (especially when debugging complex queries) if RoomDatabase had a method to set a debugging flag to receive verbose information about queries being executed.