@@ -99,7 +99,6 @@ public DataLakeStoreFileSystemClient(IAzureContext context, DataLakeStoreFileSys
99
99
if ( _isDebugEnabled )
100
100
{
101
101
_adlsLoggerConfig = new LoggingConfiguration ( ) ;
102
- cmdlet . WriteObject ( null ) ;
103
102
// Custom target that logs the debug messages from the SDK to the powershell framework's debug message queue
104
103
var adlsTarget = new AdlsLoggerTarget
105
104
{
@@ -112,9 +111,9 @@ public DataLakeStoreFileSystemClient(IAzureContext context, DataLakeStoreFileSys
112
111
var rule = new LoggingRule ( "adls.dotnet.*" , NLog . LogLevel . Debug , adlsTarget ) ;
113
112
_adlsLoggerConfig . LoggingRules . Add ( rule ) ;
114
113
115
- /* var powershellLoggingRule =
114
+ var powershellLoggingRule =
116
115
new LoggingRule ( "adls.powershell.WebTransport" , NLog . LogLevel . Debug , adlsTarget ) ;
117
- _adlsLoggerConfig.LoggingRules.Add(powershellLoggingRule);*/
116
+ _adlsLoggerConfig . LoggingRules . Add ( powershellLoggingRule ) ;
118
117
119
118
// Enable the NLog configuration to use this
120
119
LogManager . Configuration = _adlsLoggerConfig ;
@@ -207,8 +206,8 @@ public AclProcessorStats ChangeAclRecursively(string path, string accountName, L
207
206
if ( trackProgress )
208
207
{
209
208
progress = new ProgressRecord ( _uniqueActivityIdGenerator . Next ( 0 , 10000000 ) ,
210
- string . Format ( $ "Recursive acl change for path { path } and type { aclChangeType } ") ,
211
- $ "Acl { aclChangeType } ")
209
+ string . Format ( $ "Recursive acl change for path { path } ") ,
210
+ $ "Type of Acl Change: { aclChangeType } ")
212
211
{
213
212
PercentComplete = 0
214
213
} ;
@@ -220,7 +219,7 @@ public AclProcessorStats ChangeAclRecursively(string path, string accountName, L
220
219
{
221
220
progress . PercentComplete = 0 ;
222
221
progress . Activity =
223
- $ "Acl { aclChangeType } : Files enumerated: { e . FilesProcessed } Directories enumerated:{ e . DirectoryProcessed } ";
222
+ $ "Files enumerated: { e . FilesProcessed } Directories enumerated:{ e . DirectoryProcessed } ";
224
223
225
224
}
226
225
} ;
@@ -793,10 +792,10 @@ private void TrackTaskProgress(Task task, Cmdlet commandToUpdateProgressFor, Pro
793
792
794
793
if ( DateTime . Now - lastUpdate > TimeSpan . FromSeconds ( 1 ) )
795
794
{
796
- lock ( ConsoleOutputLock )
795
+ if ( taskProgress != null && ! token . IsCancellationRequested &&
796
+ ! commandToUpdateProgressFor . Stopping )
797
797
{
798
- if ( taskProgress != null && ! token . IsCancellationRequested &&
799
- ! commandToUpdateProgressFor . Stopping )
798
+ lock ( ConsoleOutputLock )
800
799
{
801
800
commandToUpdateProgressFor . WriteProgress ( taskProgress ) ;
802
801
}
0 commit comments