DotBoxD.Transports.NamedPipes 0.1.0-ci.3913

This is a prerelease version of DotBoxD.Transports.NamedPipes.
dotnet add package DotBoxD.Transports.NamedPipes --version 0.1.0-ci.3913
                    
NuGet\Install-Package DotBoxD.Transports.NamedPipes -Version 0.1.0-ci.3913
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="DotBoxD.Transports.NamedPipes" Version="0.1.0-ci.3913" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DotBoxD.Transports.NamedPipes" Version="0.1.0-ci.3913" />
                    
Directory.Packages.props
<PackageReference Include="DotBoxD.Transports.NamedPipes" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add DotBoxD.Transports.NamedPipes --version 0.1.0-ci.3913
                    
#r "nuget: DotBoxD.Transports.NamedPipes, 0.1.0-ci.3913"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package DotBoxD.Transports.NamedPipes@0.1.0-ci.3913
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=DotBoxD.Transports.NamedPipes&version=0.1.0-ci.3913&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=DotBoxD.Transports.NamedPipes&version=0.1.0-ci.3913&prerelease
                    
Install as a Cake Tool

title: 'Named Pipe Transport'

DotBoxD.Transports.NamedPipes provides first-class named-pipe client and server transports for local process-boundary IPC. It is a separate package so hosts that only need TCP or custom transports do not take a named-pipe dependency.

Install

dotnet add package DotBoxD.Transports.NamedPipes

The package depends on DotBoxD and reuses StreamConnection for framing. That means named-pipe traffic uses the same length validation, serialized sends, pooled receive buffers, and clean EOF behavior as every other stream-backed DotBoxD connection.

Host And Caller

A RpcHost turns every accepted named-pipe connection into an RpcPeer; a caller wraps a connected pipe in its own RpcPeer. The generated Provide.../Get... extension methods replace the old builder AddX/CreateXProxy calls.

using DotBoxD.Services;
using DotBoxD.Services.Generated;
using DotBoxD.Codecs.MessagePack;
using DotBoxD.Transports.NamedPipes;

var pipeName = "my-plugin-host";

await using var host = RpcHost
    .Listen(new NamedPipeServerTransport(pipeName), new MessagePackRpcSerializer())
    .ForEachPeer(peer => peer.ProvidePluginHost(new PluginHost()));
await host.StartAsync();

await using var clientTransport = new NamedPipeClientTransport(pipeName);
await clientTransport.ConnectAsync();
await using var peer = RpcPeer
    .Over(clientTransport.Connection!, new MessagePackRpcSerializer(),
          new RpcPeerOptions { RequestTimeout = TimeSpan.FromSeconds(5), RejectInboundCalls = true })
    .Start();

var pluginHost = peer.GetPluginHost();
await pluginHost.PingAsync();

RejectInboundCalls = true signals a get-only intent - the caller does not provide any service of its own. Drop it (and add Provide... calls) when the caller also needs to be called back over the same pipe. The host can react to lifecycle events via host.PeerConnected, host.PeerDisconnected, and host.AcceptError; stop it with await host.StopAsync() (disposal also stops it).

Use the (serverName, pipeName) client constructor when connecting to a remote Windows machine:

var transport = new NamedPipeClientTransport("build-agent-01", "my-plugin-host");

Duplex Peers

Named-pipe streams are duplex, so a single RpcPeer over one pipe connection can both serve and call services when both processes need to talk over the same authenticated pipe. The transports already hand back an IRpcChannel (clientTransport.Connection! / serverConnection from AcceptAsync); wrap a raw PipeStream in StreamConnection only when you manage the stream yourself. Each side calls Provide... for what it serves and Get... for what it calls:

using DotBoxD.Services;
using DotBoxD.Services.Transport;
using DotBoxD.Services.Generated;
using DotBoxD.Codecs.MessagePack;

Stream pipeStream = /* connected PipeStream */;
await using IRpcChannel connection = new StreamConnection(pipeStream, "pipe://plugin-host");

await using var peer = RpcPeer
    .Over(connection, new MessagePackRpcSerializer(),
          new RpcPeerOptions
          {
              RequestTimeout = TimeSpan.FromSeconds(5),
              InboundQueueCapacity = 256,
              QueueFullMode = QueueFullMode.Wait,
          })
    .ProvidePluginHost(new PluginHost())
    .Start();

var plugin = peer.GetPluginCallbacks();

For full symmetry both processes do the same thing - each wraps its end of the pipe in an RpcPeer, provides its own service, and gets a proxy to the other side over the one connection. Set InboundQueueCapacity (or null for unbounded) and QueueFullMode to control how queued inbound requests are handled under pressure, and raise MaxConcurrentInboundDispatch above the default 1 for bounded-concurrent dispatch instead of strict serial-per-connection handling.

RpcPeer.Disconnected reports the endpoint and the closing exception, and RpcPeer.ReadError surfaces read-loop failures with endpoint and error details. On a host, subscribe per peer inside ForEachPeer (for example peer.ReadError += ...) or watch host.PeerDisconnected for the aggregate signal.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on DotBoxD.Transports.NamedPipes:

Package Downloads
DotBoxD.Pushdown.Services

Preview DotBoxD MessagePack IPC addon that runs sandboxed kernels next to host RPC services, with named-pipe helpers.

DotBoxD.Services.All

DotBoxD service/channels bundle: the source-generated RPC core together with the MessagePack codec and TCP/named-pipe transports. Targets netstandard2.1; AOT deployments must supply generated MessagePack DTO formatters.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0-ci.3913 0 7/17/2026
0.1.0-ci.3911 0 7/17/2026
0.1.0-ci.3856 40 7/15/2026
0.1.0-ci.3828 44 7/15/2026
0.1.0-ci.3822 46 7/15/2026
0.1.0-ci.3815 46 7/15/2026
0.1.0-ci.3622 52 7/14/2026
0.1.0-ci.3617 57 7/14/2026
0.1.0-ci.3406 64 7/13/2026
0.1.0-ci.3371 60 7/13/2026
0.1.0-ci.3354 67 7/13/2026
0.1.0-ci.3342 64 7/12/2026
0.1.0-ci.3309 62 7/12/2026
0.1.0-ci.3206 72 7/12/2026
0.1.0-ci.2702 170 7/10/2026
0.1.0-ci.2630 70 7/9/2026
0.1.0-ci.2617 68 7/9/2026
0.1.0-ci.2515 69 7/9/2026
0.1.0-ci.2443 66 7/8/2026
0.1.0-ci.2369 75 7/8/2026
Loading failed