Get-ServiceFabricNode

Gets information for the all nodes in a Service Fabric cluster or for a specific node.

Syntax

Get-ServiceFabricNode
   [[-NodeName] <String>]
   [-StatusFilter <NodeStatusFilter>]
   [-ContinuationToken <String>]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]
Get-ServiceFabricNode
   [[-NodeName] <String>]
   [-StatusFilter <NodeStatusFilter>]
   [-GetSinglePage]
   [-ContinuationToken <String>]
   [-MaxResults <Int64>]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]

Description

The Get-ServiceFabricNode cmdlet gets information for all the nodes in a Service Fabric cluster or for a specific node. The returned node information includes the node name, status, type, and health state (see the Outputs section for more details).

Keep in mind that, before you perform any operation on a Service Fabric cluster you must establish a connection to the cluster by using the Connect-ServiceFabricCluster cmdlet.

Examples

Example 1: Get information for all nodes in the cluster

PS C:\> Get-ServiceFabricNode

This command returns information for all the nodes in the Service Fabric cluster.

Example 2: Get information for a specific node

PS C:\> Get-ServiceFabricNode -NodeName Node1

This command returns information for the node with the name Node1.

Required Parameters

-GetSinglePage

Specifies whether the query will return one page of query results with a continuation token value, or all pages combined into one list of results. If this option is selected, then it is the responsibility of the caller of the query to check for subsequent pages.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-ContinuationToken

Specifies the continuation token which can be used to retrieve the next page of query results.

If too many results respect the provided filters, they may not fit into one message. Paging is used to account for this by splitting the collection of returned results into separate pages. The continuation token is used to know where the previous page left off, carrying significance only to the query itself. This value should be generated from running this query, and can be passed into the next query request in order to get subsequent pages. A non-null continuation token value is returned as part of the result only if there is a subsequent page. If this value is provided without the -GetSinglePage option, then the query will return all pages starting from the continuation token value.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-MaxResults

Specifies the max number of result items that can be returned per page. This defines the upper bound for the number of results returned, not a minimum. For example, if the page fits at most 1000 returned items according to max message size restrictions defined in the configuration, and the MaxResults value is set to 2000, then only 1000 results are returned, even if 2000 result items match the query description. This value requires selection of the GetSinglePage flag; it will be ignored otherwise.

Type:Int64
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-NodeName

Specifies the name of the Service Fabric node whose information is being returned. If not specified, the cmdlet will return information for all the nodes in the cluster.

Type:String
Position:0
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-StatusFilter

Specifies the node status filter as a System.Fabric.Query.NodeStatusFilter object.

Only nodes with status matching this filter is returned in the results.

Type:NodeStatusFilter
Accepted values:Default, Up, Down, Enabling, Disabling, Disabled, Unknown, Removed, All
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-TimeoutSec

Specifies the time-out period, in seconds, for the operation.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Inputs

Get-ServiceFabricNode accepts the name of a node as a string.

Outputs

Get-ServiceFabricNode returns instances of the System.Fabric.Query.Node.