windows-powershell-docs icon indicating copy to clipboard operation
windows-powershell-docs copied to clipboard

-Timespan parameter isnt a timespan

Open Jonathan-Quilter opened this issue 2 years ago • 0 comments

given that PowerShell has New-Timespan that has a concept of a start time and an end time then this parameter name is misleading in both what type of value(s) it might accept and what its effect on the results might be.

I propose that the Get-ClusterLog function should accept a start time (-StartTime) and an end time (-EndTime) so that a specific section of the cluster log can be retrieved. For example the case where an event occurred overnight (eg 19:00 - 19:15 yesterday), which requires investigation at 09:00 today. using the current syntax you would need to execute Get-ClusterLog with a -Timespan value 840 and then subsequently remove 825 minutes of the content already drawn across the network.

If it was possible to send in a -StartTime and -EndTime parameter value of [yesterdaysdate]19:00 and [yesterdaysdate]19:15 then only the relevant part of the log would get retrieved over the network for review.

[Enter feedback here]


Document Details

Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.

Jonathan-Quilter avatar Oct 06 '22 07:10 Jonathan-Quilter