Tracing: added some details for db operations
This commit is contained in:
@@ -205,6 +205,7 @@ namespace lms::db
|
||||
|
||||
for (auto itResult{ collection.begin() }; itResult != collection.end(); ++itResult)
|
||||
{
|
||||
LMS_SCOPED_TRACE_DETAILED("Database", "ExecQueryRangeForEach");
|
||||
func(*itResult);
|
||||
lastRetrievedArtist = (*itResult)->getId();
|
||||
}
|
||||
|
||||
@@ -301,9 +301,9 @@ namespace lms::db
|
||||
}
|
||||
|
||||
auto collection{ utils::execMultiResultQuery(query) };
|
||||
|
||||
for (auto itResult{ collection.begin() }; itResult != collection.end(); ++itResult)
|
||||
{
|
||||
LMS_SCOPED_TRACE_DETAILED("Database", "ExecQueryRangeForEach");
|
||||
func(*itResult);
|
||||
lastRetrievedRelease = (*itResult)->getId();
|
||||
}
|
||||
|
||||
@@ -243,6 +243,7 @@ namespace lms::db
|
||||
|
||||
for (auto itResult{ collection.begin() }; itResult != collection.end(); ++itResult)
|
||||
{
|
||||
LMS_SCOPED_TRACE_DETAILED("Database", "ExecQueryRangeForEach");
|
||||
func(*itResult);
|
||||
lastRetrievedTrack = (*itResult)->getId();
|
||||
}
|
||||
|
||||
@@ -48,14 +48,14 @@ namespace lms::db::utils
|
||||
template <typename Query>
|
||||
auto execSingleResultQuery(const Query& query)
|
||||
{
|
||||
LMS_SCOPED_TRACE_DETAILED("Database", "ExecSingleResultQuery");
|
||||
LMS_SCOPED_TRACE_DETAILED_WITH_ARG("Database", "ExecSingleResultQuery", "Query", query.asString());
|
||||
return query.resultValue();
|
||||
}
|
||||
|
||||
template <typename Query>
|
||||
auto execMultiResultQuery(const Query& query)
|
||||
{
|
||||
LMS_SCOPED_TRACE_DETAILED("Database", "ExecMultiResultQuery");
|
||||
LMS_SCOPED_TRACE_DETAILED_WITH_ARG("Database", "ExecMultiResultQuery", "Query", query.asString());
|
||||
return query.resultList();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user