feat: thread BrowseNext continuation token through actor + BrowseService (T15)

This commit is contained in:
Joseph Doherty
2026-06-18 02:43:25 -04:00
parent d5e7e897c0
commit 9ec2450ad5
5 changed files with 79 additions and 5 deletions
@@ -40,6 +40,7 @@ public sealed class BrowseService : IBrowseService
string siteId,
string connectionName,
string? parentNodeId,
string? continuationToken = null,
CancellationToken cancellationToken = default)
{
// CentralUI-side role guard — sites don't enforce envelope-level roles,
@@ -57,7 +58,7 @@ public sealed class BrowseService : IBrowseService
{
return await _communication.BrowseNodeAsync(
siteId,
new BrowseNodeCommand(connectionName, parentNodeId),
new BrowseNodeCommand(connectionName, parentNodeId, continuationToken),
cancellationToken);
}
catch (TimeoutException ex)
@@ -28,11 +28,13 @@ public interface IBrowseService
/// <param name="siteId">The target site identifier.</param>
/// <param name="connectionName">Name of the site-local data connection to browse against — the site's <c>DataConnectionManagerActor</c> indexes its children by name.</param>
/// <param name="parentNodeId">Node to browse, or <c>null</c> to browse from the server root.</param>
/// <param name="continuationToken">Opaque cursor from a prior <see cref="BrowseNodeResult.ContinuationToken"/> to fetch the NEXT page under <paramref name="parentNodeId"/>; <c>null</c> for the first page.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A task that resolves to a <see cref="BrowseNodeResult"/> containing child nodes or a <see cref="BrowseFailure"/> on error.</returns>
Task<BrowseNodeResult> BrowseChildrenAsync(
string siteId,
string connectionName,
string? parentNodeId,
string? continuationToken = null,
CancellationToken cancellationToken = default);
}