The path to which logs are saved when the destination = PATH. This can be a
local file path on the VM, or under the mount point of a Persistent Disk or
Filestore, or a Cloud Storage path.
[[["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\u003eThe \u003ccode\u003eLogsPolicy\u003c/code\u003e class in the Batch v1alpha API describes how outputs from a Job's Tasks (stdout/stderr) will be preserved.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eLogsPolicy\u003c/code\u003e class implements interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, and inherits members from \u003ccode\u003eobject\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eLogsPolicy\u003c/code\u003e class offers constructors for creating new instances, either empty or from an existing \u003ccode\u003eLogsPolicy\u003c/code\u003e object.\u003c/p\u003e\n"],["\u003cp\u003eIt has properties like \u003ccode\u003eCloudLoggingOption\u003c/code\u003e, \u003ccode\u003eDestination\u003c/code\u003e, and \u003ccode\u003eLogsPath\u003c/code\u003e, which dictate where and how logs are saved, with options including Cloud Logging or a specified file path.\u003c/p\u003e\n"],["\u003cp\u003eThe current latest version of LogsPolicy is 1.0.0-alpha31.\u003c/p\u003e\n"]]],[],null,["# Batch v1alpha API - Class LogsPolicy (1.0.0-alpha31)\n\nVersion latestkeyboard_arrow_down\n\n- [1.0.0-alpha31 (latest)](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/latest/Google.Cloud.Batch.V1Alpha.LogsPolicy)\n- [1.0.0-alpha30](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/1.0.0-alpha30/Google.Cloud.Batch.V1Alpha.LogsPolicy) \n\n public sealed class LogsPolicy : IMessage\u003cLogsPolicy\u003e, IEquatable\u003cLogsPolicy\u003e, IDeepCloneable\u003cLogsPolicy\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Batch v1alpha API class LogsPolicy.\n\nLogsPolicy describes how outputs from a Job's Tasks (stdout/stderr) will be\npreserved. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e LogsPolicy \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[LogsPolicy](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/latest/Google.Cloud.Batch.V1Alpha.LogsPolicy), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[LogsPolicy](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/latest/Google.Cloud.Batch.V1Alpha.LogsPolicy), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[LogsPolicy](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/latest/Google.Cloud.Batch.V1Alpha.LogsPolicy), [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.Batch.V1Alpha](/dotnet/docs/reference/Google.Cloud.Batch.V1Alpha/latest/Google.Cloud.Batch.V1Alpha)\n\nAssembly\n--------\n\nGoogle.Cloud.Batch.V1Alpha.dll\n\nConstructors\n------------\n\n### LogsPolicy()\n\n public LogsPolicy()\n\n### LogsPolicy(LogsPolicy)\n\n public LogsPolicy(LogsPolicy other)\n\nProperties\n----------\n\n### CloudLoggingOption\n\n public LogsPolicy.Types.CloudLoggingOption CloudLoggingOption { get; set; }\n\nOptional. Additional settings for Cloud Logging. It will only take effect\nwhen the destination of `LogsPolicy` is set to `CLOUD_LOGGING`.\n\n### Destination\n\n public LogsPolicy.Types.Destination Destination { get; set; }\n\nWhere logs should be saved.\n\n### LogsPath\n\n public string LogsPath { get; set; }\n\nThe path to which logs are saved when the destination = PATH. This can be a\nlocal file path on the VM, or under the mount point of a Persistent Disk or\nFilestore, or a Cloud Storage path."]]