Editar

Compartir a través de


Remove-CsRgsQueue

Deletes an existing Response Group queue. With the Response Group application, phone calls are put in a queue and callers are placed on hold until a Response Group agent is available to answer that call. This cmdlet was introduced in Lync Server 2010.

Syntax

Remove-CsRgsQueue
      [-Force]
      [-WhatIf]
      [-Confirm]
      -Instance <Queue>
      [<CommonParameters>]

Description

When someone calls a phone number associated with the Response Group application one of two things typically happens: either the call is transferred to a question that the caller must answer in order to continue (for example, "Press 1 for hardware support; press 2 for software support") or the call is placed in a queue until a Response Group agent is available to answer the call.

Instead of having a single queue for all phone calls, the Response Group application enables you to create multiple queues that can be associated with different workflows and different Response Group agent groups. In turn, this means queues can respond differently to events such as a designated number of calls being simultaneously held in the queue, or to callers that have been on hold for specified amount of time.

In addition to creating new queues you can also remove existing queues; that's what the Remove-CsRgsQueue cmdlet is for. Note that, by default, you will be prompted if you try to remove a queue that is currently assigned to an active workflow; the prompt will ask you to verify that you want to delete the queue and Windows PowerShell will pause (and no queue will be deleted) until you answer the prompt. To bypass the prompt and to delete queues that are being used by an active workflow, add the Force parameter. For example:

Get-CsRgsQueue -Identity "service:ApplicationServer:atl-cs-001.litwareinc.com" | Remove-CsRgsQueue -Force

Remove-CsRgsQueue always checks to see if a queue is being used by an active workflow before it will delete that queue. However, the cmdlet does not verify whether or not the queue is being used by another queue as either the timeout or overflow queue. That means it is possible to delete a queue that is needed by another queue. Because of that, you might want to use the Get-CsRgsQueue cmdlet to check the OverflowAction and TimeoutAction properties of your other Response Group queues before running Remove-CsRgsQueue to delete a queue.

Examples

-------------------------- Example 1 ------------------------

Get-CsRgsQueue -Identity service:ApplicationServer:atl-cs-001.litwareinc.com | Remove-CsRgsQueue

The command shown in Example 1 deletes all the Response Group queues found on the service ApplicationServer:atl-cs-001.litwareinc.com. To do this, the command first uses Get-CsRgsQueue to return a collection of all the queues found on ApplicationServer:atl-cs-001.litwareinc.com. This collection is then piped to Remove-CsRgsQueue, which deletes each queue in the collection.

-------------------------- Example 2 ------------------------

Get-CsRgsQueue -Identity service:ApplicationServer:atl-cs-001.litwareinc.com -Name "Help Desk Queue" | Remove-CsRgsQueue

In Example 2, a single Response Group queue is deleted: the queue named "Help Desk Queue", located on the service ApplicationServer:atl-cs-001.litwareinc.com. To delete this queue, Get-CsRgsQueue is called along with the Identity and Name parameters; the single queue returned by this call is then piped to and deleted by, Remove-CsRgsQueue.

-------------------------- Example 3 ------------------------

Get-CsRgsQueue -Identity service:ApplicationServer:atl-cs-001.litwareinc.com | Where-Object {$_.OverflowCandidate -eq "NewestCall"} | Remove-CsRgsQueue

Example 3 deletes all the Response Group queues found on the service ApplicationServer:atl-cs-001.litwareinc.com, provided those queues have their OverflowCandidate property set to NewestCall. To do this, Get-CsRgsQueue is first called in order to return a collection of all the Response Group queues found on ApplicationServer:atl-cs-001.litwareinc.com. This collection is then piped to the Where-Object cmdlet, which selects only those queues where the OverflowCandidate property is equal to "NewestCall". The filtered collection is then piped to Remove-CsRgsQueue, which deletes each queue in the collection.

Parameters

-Confirm

Prompts you for confirmation before executing the command.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-Force

Forces the deletion of a Response Group queue. If this parameter is present, the queue will be deleted without warning, even if the queue is assigned to an active workflow. If this parameter is not present then you will be asked to confirm the deletion of any queue currently in use by an active workflow.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-Instance

Object reference pointing to the queue to be removed. When piping workflow objects to Remove-CsRgsQueue you can leave off the Instance parameter.

To use the Instance parameter use commands similar to this:

$x = Get-CsRgsQueue -Identity ApplicationServer:atl-cs-001.litwareinc.com /1987d3c2-4544-489d-bbe3-59f79f530a83

Remove-CsRgsQueue -Instance $x

Note that you can only remove a single queue at a time when using the Instance parameter. That means that your object reference ($x) cannot contain multiple queue objects.

Type:Queue
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-WhatIf

Describes what would happen if you executed the command without actually executing the command.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

Inputs

Microsoft.Rtc.Rgs.Management.WritableSettings.Queue object. Remove-CsRgsQueue accepts pipelined instances of the Response Group queue object.

Outputs

Remove-CsRgsQueue deletes existing instances of the Microsoft.Rtc.Rgs.Management.WritableSettings.Queue object.