Tracing span adjustments for ret verbosity.
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
@@ -130,7 +130,12 @@ impl Service {
|
||||
}
|
||||
|
||||
/// Returns the private read marker PDU count.
|
||||
#[tracing::instrument(skip(self), level = "debug", name = "get_private_count", ret)]
|
||||
#[tracing::instrument(
|
||||
name = "get_private_count",
|
||||
level = "debug",
|
||||
skip(self),
|
||||
ret(level = "trace")
|
||||
)]
|
||||
pub async fn private_read_get_count(
|
||||
&self,
|
||||
room_id: &RoomId,
|
||||
@@ -142,14 +147,24 @@ impl Service {
|
||||
}
|
||||
|
||||
/// Returns the PDU count of the last typing update in this room.
|
||||
#[tracing::instrument(skip(self), level = "debug", name = "get_private_last", ret)]
|
||||
#[tracing::instrument(
|
||||
name = "get_private_last",
|
||||
level = "debug",
|
||||
skip(self),
|
||||
ret(level = "trace")
|
||||
)]
|
||||
pub async fn last_privateread_update(&self, user_id: &UserId, room_id: &RoomId) -> u64 {
|
||||
self.db
|
||||
.last_privateread_update(user_id, room_id)
|
||||
.await
|
||||
}
|
||||
|
||||
#[tracing::instrument(skip(self), level = "debug", name = "get_receipt_last", ret)]
|
||||
#[tracing::instrument(
|
||||
name = "get_receipt_last",
|
||||
level = "debug",
|
||||
skip(self),
|
||||
ret(level = "trace")
|
||||
)]
|
||||
pub async fn last_receipt_count(
|
||||
&self,
|
||||
room_id: &RoomId,
|
||||
|
||||
@@ -471,7 +471,7 @@ pub async fn get_room_version_rules(&self, room_id: &RoomId) -> Result<RoomVersi
|
||||
#[tracing::instrument(
|
||||
level = "debug"
|
||||
skip(self),
|
||||
ret,
|
||||
ret(level = "trace"),
|
||||
)]
|
||||
pub async fn get_room_version(&self, room_id: &RoomId) -> Result<RoomVersionId> {
|
||||
self.services
|
||||
@@ -488,7 +488,7 @@ pub async fn get_room_version(&self, room_id: &RoomId) -> Result<RoomVersionId>
|
||||
#[tracing::instrument(
|
||||
level = "debug"
|
||||
skip(self),
|
||||
ret,
|
||||
ret(level = "trace"),
|
||||
)]
|
||||
pub async fn get_room_shortstatehash(&self, room_id: &RoomId) -> Result<ShortStateHash> {
|
||||
self.db
|
||||
@@ -513,7 +513,7 @@ pub async fn pdu_shortstatehash(&self, event_id: &EventId) -> Result<ShortStateH
|
||||
#[tracing::instrument(
|
||||
level = "debug"
|
||||
skip(self),
|
||||
ret,
|
||||
ret(level = "trace"),
|
||||
)]
|
||||
pub async fn get_shortstatehash(&self, shorteventid: ShortEventId) -> Result<ShortStateHash> {
|
||||
const BUFSIZE: usize = size_of::<ShortEventId>();
|
||||
|
||||
@@ -54,7 +54,7 @@ pub fn reset_notification_counts(&self, user_id: &UserId, room_id: &RoomId) {
|
||||
}
|
||||
|
||||
#[implement(Service)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret(level = "trace"))]
|
||||
pub async fn notification_count(&self, user_id: &UserId, room_id: &RoomId) -> u64 {
|
||||
let key = (user_id, room_id);
|
||||
self.db
|
||||
@@ -66,7 +66,7 @@ pub async fn notification_count(&self, user_id: &UserId, room_id: &RoomId) -> u6
|
||||
}
|
||||
|
||||
#[implement(Service)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret(level = "trace"))]
|
||||
pub async fn highlight_count(&self, user_id: &UserId, room_id: &RoomId) -> u64 {
|
||||
let key = (user_id, room_id);
|
||||
self.db
|
||||
@@ -78,7 +78,7 @@ pub async fn highlight_count(&self, user_id: &UserId, room_id: &RoomId) -> u64 {
|
||||
}
|
||||
|
||||
#[implement(Service)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret)]
|
||||
#[tracing::instrument(level = "debug", skip(self), ret(level = "trace"))]
|
||||
pub async fn last_notification_read(&self, user_id: &UserId, room_id: &RoomId) -> u64 {
|
||||
let key = (room_id, user_id);
|
||||
self.db
|
||||
|
||||
Reference in New Issue
Block a user