Set-SPServiceApplicationEndpoint
適用版本: SharePoint Foundation 2010, SharePoint Server 2010
上次修改主題的時間: 2015-03-09
設定服務應用程式的端點主機。
Syntax
Set-SPServiceApplicationEndpoint [-Identity] <SPServiceEndpointPipeBind> -HostName <String> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]
Set-SPServiceApplicationEndpoint [-Identity] <SPServiceEndpointPipeBind> -ResetHostName <SwitchParameter> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]
詳細描述
Set- SPServiceApplicationEndpoint Cmdlet 會設定服務端點的主機。使用第二個參數集可重設服務端點主機,以使用預設端點。
Parameters
參數 | 必要 | 類型 | 描述 |
---|---|---|---|
Identity |
必要 |
Microsoft.SharePoint.PowerShell.SPServiceEndpointPipeBind |
指定要更新的服務端點。 此類型必須是格式為 12345678-90ab-cdef-1234-567890bcdefgh 的有效 GUID;格式為 http://sitename:8003/servicemodelsamples/service 之有效端點位址的 URI;或有效之 SPServiceEndpoint 物件的執行個體。 |
HostName |
必要 |
System.String |
指定服務端點的預設主機。 此類型必須是有效的完全負載平衡 URL,格式為 http://server_name。 |
ResetHostName |
必要 |
System.Management.Automation.SwitchParameter |
移除目前的服務端點主機,並使用預設的主機。 |
AssignmentCollection |
選用 |
Microsoft.SharePoint.PowerShell.SPAssignmentCollection |
為能適當處置物件而管理物件。使用 SPWeb 或 SPSite 等物件可能會耗用大量的記憶體,因此在 Windows PowerShell 指令碼中使用這些物件時,必須適當地管理記憶體。您可以使用 SPAssignment 物件將物件指派給變數,並在不需要時處置這些物件,以釋放記憶體。使用 SPWeb、SPSite 或 SPSiteAdministration 物件時,若未使用指派集合或 Global 參數,將會自動處置這些物件。 注意 使用 Global 參數時,所有物件會包含在全域儲存區內。若未立即使用物件,或未使用 Stop-SPAssignment 命令處置物件,將會發生記憶體不足的狀況。 |
Confirm |
選用 |
System.Management.Automation.SwitchParameter |
執行命令之前,會先提示您進行確認。如需詳細資訊,請輸入下列命令:get-help about_commonparameters |
WhatIf |
選用 |
System.Management.Automation.SwitchParameter |
顯示訊息描述命令效果,而非描述命令執行的效果。如需詳細資訊,請輸入下列命令:get-help about_commonparameters |
輸入類型
傳回類型
Example
--------------------範例-------------------
Set-SPServiceApplicationEndpoint -Identity "ServiceApp1" -HostName http://sitename -ResetHostName $true
這個範例會將 SPServiceEndpoint 物件與指定的身分識別建立關聯,並且重設主機名稱。