Revierta el plano de control del núcleo de paquetes especificado a la versión anterior, "rollbackVersion". No se pueden revertir varias reversiones consecutivas. Esta acción puede provocar una interrupción del servicio.
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MobileNetwork/packetCoreControlPlanes/{packetCoreControlPlaneName}/rollback?api-version=2024-04-01
Parámetros de identificador URI
Nombre |
En |
Requerido |
Tipo |
Description |
packetCoreControlPlaneName
|
path |
True
|
string
|
Nombre del plano de control del núcleo del paquete.
Patrón de Regex: ^[a-zA-Z0-9][a-zA-Z0-9_-]*$
|
resourceGroupName
|
path |
True
|
string
|
Nombre del grupo de recursos. El nombre distingue mayúsculas de minúsculas.
|
subscriptionId
|
path |
True
|
string
uuid
|
Identificador de la suscripción de destino. El valor debe ser un UUID.
|
api-version
|
query |
True
|
string
|
Versión de API que se usará para la operación.
|
Respuestas
Nombre |
Tipo |
Description |
200 OK
|
AsyncOperationStatus
|
Operación asincrónica completada.
|
202 Accepted
|
|
Accepted. Devuelve un URI de operación que se puede consultar para encontrar el estado actual de la operación.
|
Other Status Codes
|
ErrorResponse
|
Respuesta de error que describe el motivo del error de la operación.
|
Seguridad
azure_auth
Flujo de OAuth2 de Azure Active Directory.
Tipo:
oauth2
Flujo:
implicit
Dirección URL de autorización:
https://login.microsoftonline.com/common/oauth2/authorize
Ámbitos
Nombre |
Description |
user_impersonation
|
suplantación de su cuenta de usuario
|
Ejemplos
Rollback packet core control plane
Solicitud de ejemplo
POST https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.MobileNetwork/packetCoreControlPlanes/TestPacketCoreCP/rollback?api-version=2024-04-01
/**
* Samples for PacketCoreControlPlanes Rollback.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/mobilenetwork/resource-manager/Microsoft.MobileNetwork/stable/2024-04-01/examples/
* PacketCoreControlPlaneRollback.json
*/
/**
* Sample code: Rollback packet core control plane.
*
* @param manager Entry point to MobileNetworkManager.
*/
public static void
rollbackPacketCoreControlPlane(com.azure.resourcemanager.mobilenetwork.MobileNetworkManager manager) {
manager.packetCoreControlPlanes().rollback("rg1", "TestPacketCoreCP", com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.mobilenetwork import MobileNetworkManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-mobilenetwork
# USAGE
python packet_core_control_plane_rollback.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = MobileNetworkManagementClient(
credential=DefaultAzureCredential(),
subscription_id="00000000-0000-0000-0000-000000000000",
)
response = client.packet_core_control_planes.begin_rollback(
resource_group_name="rg1",
packet_core_control_plane_name="TestPacketCoreCP",
).result()
print(response)
# x-ms-original-file: specification/mobilenetwork/resource-manager/Microsoft.MobileNetwork/stable/2024-04-01/examples/PacketCoreControlPlaneRollback.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armmobilenetwork_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/mobilenetwork/armmobilenetwork/v4"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d88c94b22a8efdd47c0cadfe6d8d489107db2b23/specification/mobilenetwork/resource-manager/Microsoft.MobileNetwork/stable/2024-04-01/examples/PacketCoreControlPlaneRollback.json
func ExamplePacketCoreControlPlanesClient_BeginRollback() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armmobilenetwork.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewPacketCoreControlPlanesClient().BeginRollback(ctx, "rg1", "TestPacketCoreCP", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to pull the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AsyncOperationStatus = armmobilenetwork.AsyncOperationStatus{
// Name: to.Ptr("testOperation"),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
// ID: to.Ptr("/providers/Microsoft.MobileNetwork/locations/testLocation/operationStatuses/testOperation"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
// Status: to.Ptr("Succeeded"),
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { MobileNetworkManagementClient } = require("@azure/arm-mobilenetwork");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to Roll back the specified packet core control plane to the previous version, "rollbackVersion". Multiple consecutive rollbacks are not possible. This action may cause a service outage.
*
* @summary Roll back the specified packet core control plane to the previous version, "rollbackVersion". Multiple consecutive rollbacks are not possible. This action may cause a service outage.
* x-ms-original-file: specification/mobilenetwork/resource-manager/Microsoft.MobileNetwork/stable/2024-04-01/examples/PacketCoreControlPlaneRollback.json
*/
async function rollbackPacketCoreControlPlane() {
const subscriptionId =
process.env["MOBILENETWORK_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000";
const resourceGroupName = process.env["MOBILENETWORK_RESOURCE_GROUP"] || "rg1";
const packetCoreControlPlaneName = "TestPacketCoreCP";
const credential = new DefaultAzureCredential();
const client = new MobileNetworkManagementClient(credential, subscriptionId);
const result = await client.packetCoreControlPlanes.beginRollbackAndWait(
resourceGroupName,
packetCoreControlPlaneName,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Respuesta de muestra
{
"id": "/providers/Microsoft.MobileNetwork/locations/testLocation/operationStatuses/testOperation",
"name": "testOperation",
"status": "Succeeded",
"startTime": "2021-08-19T03:36:07.000Z",
"endTime": "2021-08-19T03:38:07.000Z"
}
Azure-AsyncOperation: https://management.azure.com/providers/Microsoft.MobileNetwork/locations/testLocation/operationStatuses/testOperation?api-version=2024-04-01
Definiciones
AsyncOperationStatus
Estado actual de una operación asincrónica.
Nombre |
Tipo |
Description |
endTime
|
string
|
La hora de finalización de la operación.
|
error
|
ErrorDetail
|
Si está presente, detalles del error de operación.
|
id
|
string
|
Identificador completo de la operación asincrónica.
|
name
|
string
|
Nombre de la operación asincrónica.
|
percentComplete
|
number
|
Porcentaje de la operación completada.
|
properties
|
object
|
Propiedades devueltas por el proveedor de recursos en una operación correcta
|
resourceId
|
string
|
Identificador completo del recurso al que se relaciona este estado de operación asincrónica.
|
startTime
|
string
|
La hora de inicio de la operación.
|
status
|
string
|
El estado de la operación.
|
ErrorAdditionalInfo
Información adicional sobre el error de administración de recursos.
Nombre |
Tipo |
Description |
info
|
object
|
Información adicional.
|
type
|
string
|
Tipo de información adicional.
|
ErrorDetail
Detalle del error.
Nombre |
Tipo |
Description |
additionalInfo
|
ErrorAdditionalInfo[]
|
Información adicional del error.
|
code
|
string
|
Código de error.
|
details
|
ErrorDetail[]
|
Los detalles del error.
|
message
|
string
|
El mensaje de error.
|
target
|
string
|
Destino del error.
|
ErrorResponse
Respuesta de error
Nombre |
Tipo |
Description |
error
|
ErrorDetail
|
Objeto de error.
|