Add query for alias existing; tweak tracing spans.
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
@@ -150,7 +150,7 @@ impl Service {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[tracing::instrument(skip(self), level = "debug")]
|
#[tracing::instrument(skip(self), level = "trace")]
|
||||||
pub async fn resolve_local_alias(&self, alias: &RoomAliasId) -> Result<OwnedRoomId> {
|
pub async fn resolve_local_alias(&self, alias: &RoomAliasId) -> Result<OwnedRoomId> {
|
||||||
self.db
|
self.db
|
||||||
.alias_roomid
|
.alias_roomid
|
||||||
@@ -159,6 +159,15 @@ impl Service {
|
|||||||
.deserialized()
|
.deserialized()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[tracing::instrument(skip(self), level = "trace")]
|
||||||
|
pub async fn local_alias_exists(&self, alias: &RoomAliasId) -> bool {
|
||||||
|
self.db
|
||||||
|
.alias_roomid
|
||||||
|
.exists(alias.alias())
|
||||||
|
.await
|
||||||
|
.is_ok()
|
||||||
|
}
|
||||||
|
|
||||||
#[tracing::instrument(skip(self), level = "debug")]
|
#[tracing::instrument(skip(self), level = "debug")]
|
||||||
pub fn local_aliases_for_room<'a>(
|
pub fn local_aliases_for_room<'a>(
|
||||||
&'a self,
|
&'a self,
|
||||||
@@ -264,6 +273,7 @@ impl Service {
|
|||||||
Ok(None)
|
Ok(None)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[tracing::instrument(skip(self, appservice_info), level = "trace")]
|
||||||
pub async fn appservice_checks(
|
pub async fn appservice_checks(
|
||||||
&self,
|
&self,
|
||||||
room_alias: &RoomAliasId,
|
room_alias: &RoomAliasId,
|
||||||
|
|||||||
Reference in New Issue
Block a user