public sealed class MaintenancePolicy : IMessage<MaintenancePolicy>, IEquatable<MaintenancePolicy>, IDeepCloneable<MaintenancePolicy>, IBufferMessage, IMessage
Reference documentation and code samples for the Google Cloud Memorystore for Memcache v1beta2 API class MaintenancePolicy.
public RepeatedField<WeeklyMaintenanceWindow> WeeklyMaintenanceWindow { get; }
Required. Maintenance window that is applied to resources covered by this
policy. Minimum 1. For the current version, the maximum number of
weekly_maintenance_windows is expected to be one.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThis document provides reference documentation for the \u003ccode\u003eMaintenancePolicy\u003c/code\u003e class within the Google Cloud Memorystore for Memcache v1beta2 API.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eMaintenancePolicy\u003c/code\u003e class is used to define a maintenance policy per instance, inheriting from \u003ccode\u003eobject\u003c/code\u003e and implementing several interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eMaintenancePolicy\u003c/code\u003e class includes properties like \u003ccode\u003eCreateTime\u003c/code\u003e, \u003ccode\u003eDescription\u003c/code\u003e, \u003ccode\u003eUpdateTime\u003c/code\u003e, and \u003ccode\u003eWeeklyMaintenanceWindow\u003c/code\u003e, which define the policy's creation and update times, a description of the policy, and the maintenance windows.\u003c/p\u003e\n"],["\u003cp\u003eThere are two constructors available for creating \u003ccode\u003eMaintenancePolicy\u003c/code\u003e objects, one being the basic \u003ccode\u003eMaintenancePolicy()\u003c/code\u003e, and the other is \u003ccode\u003eMaintenancePolicy(MaintenancePolicy other)\u003c/code\u003e, which takes in an existing policy as a parameter.\u003c/p\u003e\n"],["\u003cp\u003eThe latest version of this API is \u003ccode\u003e2.0.0-beta06\u003c/code\u003e, although there are older versions such as \u003ccode\u003e2.0.0-beta05\u003c/code\u003e and \u003ccode\u003e1.0.0-beta05\u003c/code\u003e available.\u003c/p\u003e\n"]]],[],null,["# Google Cloud Memorystore for Memcache v1beta2 API - Class MaintenancePolicy (2.0.0-beta06)\n\nVersion latestkeyboard_arrow_down\n\n- [2.0.0-beta06 (latest)](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/latest/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy)\n- [2.0.0-beta05](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/2.0.0-beta05/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy)\n- [1.0.0-beta05](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/1.0.0-beta05/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy) \n\n public sealed class MaintenancePolicy : IMessage\u003cMaintenancePolicy\u003e, IEquatable\u003cMaintenancePolicy\u003e, IDeepCloneable\u003cMaintenancePolicy\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Google Cloud Memorystore for Memcache v1beta2 API class MaintenancePolicy.\n\nMaintenance policy per instance. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e MaintenancePolicy \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[MaintenancePolicy](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/latest/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[MaintenancePolicy](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/latest/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[MaintenancePolicy](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/latest/Google.Cloud.Memcache.V1Beta2.MaintenancePolicy), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Memcache.V1Beta2](/dotnet/docs/reference/Google.Cloud.Memcache.V1Beta2/latest/Google.Cloud.Memcache.V1Beta2)\n\nAssembly\n--------\n\nGoogle.Cloud.Memcache.V1Beta2.dll\n\nConstructors\n------------\n\n### MaintenancePolicy()\n\n public MaintenancePolicy()\n\n### MaintenancePolicy(MaintenancePolicy)\n\n public MaintenancePolicy(MaintenancePolicy other)\n\nProperties\n----------\n\n### CreateTime\n\n public Timestamp CreateTime { get; set; }\n\nOutput only. The time when the policy was created.\n\n### Description\n\n public string Description { get; set; }\n\nDescription of what this policy is for. Create/Update methods\nreturn INVALID_ARGUMENT if the length is greater than 512.\n\n### UpdateTime\n\n public Timestamp UpdateTime { get; set; }\n\nOutput only. The time when the policy was updated.\n\n### WeeklyMaintenanceWindow\n\n public RepeatedField\u003cWeeklyMaintenanceWindow\u003e WeeklyMaintenanceWindow { get; }\n\nRequired. Maintenance window that is applied to resources covered by this\npolicy. Minimum 1. For the current version, the maximum number of\nweekly_maintenance_windows is expected to be one."]]