Upravit

Sdílet prostřednictvím


Update-AzApiManagementCache

updates a cache in Api Management service.

Syntax

Update-AzApiManagementCache
      -Context <PsApiManagementContext>
      -CacheId <String>
      [-ConnectionString <String>]
      [-AzureRedisResourceId <String>]
      [-Description <String>]
      [-UseFromLocation <String>]
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzApiManagementCache
      -InputObject <PsApiManagementCache>
      [-ConnectionString <String>]
      [-AzureRedisResourceId <String>]
      [-Description <String>]
      [-UseFromLocation <String>]
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzApiManagementCache
      -ResourceId <String>
      [-ConnectionString <String>]
      [-AzureRedisResourceId <String>]
      [-Description <String>]
      [-UseFromLocation <String>]
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]

Description

The cmdlet Update-AzApiManagementCache updates a cache in the ApiManagement service.

Examples

Example 1 : Updates the Description of the Cache in centralus

$context=New-AzApiManagementContext -ResourceGroupName Api-Default-Central-US -ServiceName contoso
Update-AzApiManagementCache -Context $context -CacheId centralus -Description "Team new cache" -PassThru

CacheId              : centralus
Description          : Team new cache
ConnectionString     : {{5cc19889e6ed3b0524c3f7d3}}
AzureRedisResourceId :
Id                   : /subscriptions/subid/resourceGroups/Api-Default-Central-US/providers/M
                       icrosoft.ApiManagement/service/contoso/caches/centralus
ResourceGroupName    : Api-Default-Central-US
ServiceName          : contoso

Updates the description of the Cache in Central US.

Parameters

-AzureRedisResourceId

Arm ResourceId of the Azure Redis Cache instance. This parameter is optional.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-CacheId

Identifier of new cache. This parameter is required.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

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

-ConnectionString

Redis Connection String. This parameter is optional.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Context

Instance of PsApiManagementContext. This parameter is required.

Type:PsApiManagementContext
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Description

Cache Description. This parameter is optional.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-InputObject

Instance of PsApiManagementCache. This parameter is required.

Type:PsApiManagementCache
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-PassThru

If specified then instance of Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementCache type representing the modified cache will be written to output.

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

-ResourceId

Arm ResourceId of Cache. This parameter is required.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-UseFromLocation

Cache UseFromLocation. This parameter is optional, default value 'default'.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

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

Inputs

PsApiManagementContext

String

PsApiManagementCache

SwitchParameter

Outputs

PsApiManagementCache