Class BowireReverseProxyHost
- Namespace
- Kuestenlogik.Bowire.Interceptor
- Assembly
- Kuestenlogik.Bowire.Interceptor.dll
Boots a standalone reverse-proxy host that fronts an upstream service (#307 — Phase C of the #153 interceptor track; YARP migration in #323). Two Kestrel hosts come up side-by-side:
- the edge listener clients point at — every request forwarded upstream by Kuestenlogik.Bowire.Interceptor.BowireReverseProxyMiddleware using YARP's Yarp.ReverseProxy.Forwarder.IHttpForwarder.SendAsync(HttpContext, string, HttpMessageInvoker, ForwarderRequestConfig, HttpTransformer), captured into InterceptedFlowStore;
- the sidecar API the workbench's "Intercepted" rail
reads (
/api/intercepted/flows//stream), backed by the same store singleton.
public sealed class BowireReverseProxyHost : IAsyncDisposable
- Inheritance
-
BowireReverseProxyHost
- Implements
- Inherited Members
Remarks
The split-host shape mirrors bowire proxy's proxy + sidecar
API design exactly, so an operator who learned one transfers
straight to the other. Stop semantics are graceful — cancelling the
supplied CancellationToken stops both hosts and
disposes the forwarding HttpMessageInvoker.
Properties
EdgePort
The actual TCP port the edge listener bound to (0 -> ephemeral).
public int EdgePort { get; }
Property Value
Store
The flow store the edge middleware writes captures into.
public InterceptedFlowStore Store { get; }
Property Value
Methods
Create(BowireReverseProxyHostOptions)
Build a configured reverse-proxy host. Does NOT start the listener — call StartAsync(CancellationToken). The split lets the CLI catch bind failures separately from forwarder-setup failures.
public static BowireReverseProxyHost Create(BowireReverseProxyHostOptions options)
Parameters
optionsBowireReverseProxyHostOptions
Returns
DisposeAsync()
public ValueTask DisposeAsync()
Returns
StartAsync(CancellationToken)
Start the edge listener. After this returns, EdgePort is bound.
public Task StartAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationToken
Returns
StopAsync(CancellationToken)
Stop the edge listener (idempotent). Sidecar API stops via its own caller.
public Task StopAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationToken