OutOfProcessNodeInstance Class

Definition

Caution

Use Microsoft.AspNetCore.SpaServices.Extensions

Class responsible for launching a Node child process on the local machine, determining when it is ready to accept invocations, detecting if it dies on its own, and finally terminating it on disposal.

This abstract base class uses the input/output streams of the child process to perform a simple handshake to determine when the child process is ready to accept invocations. This is agnostic to the mechanism that derived classes use to actually perform the invocations (e.g., they could use HTTP-RPC, or a binary TCP protocol, or any other RPC-type mechanism).

C#
public abstract class OutOfProcessNodeInstance : IDisposable, Microsoft.AspNetCore.NodeServices.HostingModels.INodeInstance
C#
[System.Obsolete("Use Microsoft.AspNetCore.SpaServices.Extensions")]
public abstract class OutOfProcessNodeInstance : IDisposable, Microsoft.AspNetCore.NodeServices.HostingModels.INodeInstance
Inheritance
OutOfProcessNodeInstance
Attributes
Implements

Constructors

Fields

OutputLogger

The ILogger to which the Node.js instance's stdout/stderr is being redirected.

Methods

Dispose()

Disposes this instance.

Dispose(Boolean)

Disposes the instance.

Finalize()

Implements the finalization part of the IDisposable pattern by calling Dispose(false).

InvokeExportAsync<T>(CancellationToken, String, String, Object[])

Asynchronously invokes code in the Node.js instance.

InvokeExportAsync<T>(NodeInvocationInfo, CancellationToken)

Asynchronously invokes code in the Node.js instance.

OnErrorDataReceived(String)

Virtual method invoked whenever the Node.js process emits a line to its stderr.

OnOutputDataReceived(String)

Virtual method invoked whenever the Node.js process emits a line to its stdout.

PrepareNodeProcessStartInfo(String, String, String, IDictionary<String,String>, Boolean, Int32)

Configures a ProcessStartInfo instance describing how to launch the Node.js process.

Applies to

Product Versions (Obsolete)
ASP.NET Core 2.0, 2.1, 2.2 (3.0, 3.1)

See also