chore: retire openhub and pi ts runtime

This commit is contained in:
Agent Board
2026-07-12 14:18:26 +08:00
parent 62959b0c4d
commit 2f5902e3e7
45 changed files with 367 additions and 925 deletions
@@ -5,7 +5,6 @@ use crate::page_aggregate::{
PageAggregate, PageAggregateSource, PageBody, PageHead, PageIdentity, PageLayout, PageOptions,
PagePermissions, PageStats, PageTree,
};
use crate::provider_identity_sync::sync_openhub_directory_permissions_for_user_id;
use crate::routes::local_markdown_parser::{
file_stem_title, parse_markdown_attachment_refs, parse_markdown_page, split_frontmatter,
};
@@ -2442,14 +2441,6 @@ pub async fn create_local_access_grant(
) -> Result<(StatusCode, Json<Value>), WebError> {
let payload = add_control_plane_local_access_grant_for_context(&state, &context, request)
.map_err(|error| error.with_context(&context))?;
if let Some(user_id) = payload
.pointer("/grant/userId")
.and_then(Value::as_str)
.map(str::trim)
.filter(|value| !value.is_empty())
{
sync_openhub_directory_permissions_for_user_id(state.control_plane(), user_id).await;
}
Ok((StatusCode::OK, Json(payload)))
}
@@ -2460,14 +2451,6 @@ pub async fn create_user_access_grant(
) -> Result<(StatusCode, Json<Value>), WebError> {
let payload = add_control_plane_user_access_grant_for_context(&state, &context, request)
.map_err(|error| error.with_context(&context))?;
if let Some(user_id) = payload
.pointer("/grant/userId")
.and_then(Value::as_str)
.map(str::trim)
.filter(|value| !value.is_empty())
{
sync_openhub_directory_permissions_for_user_id(state.control_plane(), user_id).await;
}
Ok((StatusCode::OK, Json(payload)))
}
@@ -2478,14 +2461,6 @@ pub async fn delete_local_access_grant(
) -> Result<(StatusCode, Json<Value>), WebError> {
let payload = delete_control_plane_local_access_grant_for_context(&state, &context, &grant_id)
.map_err(|error| error.with_context(&context))?;
if let Some(user_id) = payload
.get("revokedUserId")
.and_then(Value::as_str)
.map(str::trim)
.filter(|value| !value.is_empty())
{
sync_openhub_directory_permissions_for_user_id(state.control_plane(), user_id).await;
}
Ok((StatusCode::OK, Json(payload)))
}
@@ -2496,14 +2471,6 @@ pub async fn delete_user_access_grant(
) -> Result<(StatusCode, Json<Value>), WebError> {
let payload = delete_control_plane_user_access_grant_for_context(&state, &context, &grant_id)
.map_err(|error| error.with_context(&context))?;
if let Some(user_id) = payload
.get("revokedUserId")
.and_then(Value::as_str)
.map(str::trim)
.filter(|value| !value.is_empty())
{
sync_openhub_directory_permissions_for_user_id(state.control_plane(), user_id).await;
}
Ok((StatusCode::OK, Json(payload)))
}