SearchLog allow for search Or / And the multiple terms

This commit is contained in:
mbecker20
2024-04-12 04:36:10 -07:00
parent 4523f3e112
commit a2d301bfbc
8 changed files with 61 additions and 12 deletions

View File

@@ -130,7 +130,11 @@ impl Resolve<GetLog, User> for State {
impl Resolve<SearchLog, User> for State {
async fn resolve(
&self,
SearchLog { deployment, terms }: SearchLog,
SearchLog {
deployment,
terms,
combinator,
}: SearchLog,
user: User,
) -> anyhow::Result<Log> {
let Deployment {
@@ -148,7 +152,11 @@ impl Resolve<SearchLog, User> for State {
}
let server = Server::get_resource(&server_id).await?;
periphery_client(&server)?
.request(api::container::GetContainerLogSearch { name, terms })
.request(api::container::GetContainerLogSearch {
name,
terms,
combinator,
})
.await
.context("failed at call to periphery")
}