File tree Expand file tree Collapse file tree 3 files changed +12
-6
lines changed
docs/trace/extending-the-sdk Expand file tree Collapse file tree 3 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -50,9 +50,10 @@ public override ExportResult Export(in Batch<Activity> batch)
5050 return ExportResult . Success ;
5151 }
5252
53- protected override void OnShutdown ( int timeoutMilliseconds )
53+ protected override bool OnShutdown ( int timeoutMilliseconds )
5454 {
5555 Console . WriteLine ( $ "{ this . name } .OnShutdown(timeoutMilliseconds={ timeoutMilliseconds } )") ;
56+ return true ;
5657 }
5758
5859 protected override void Dispose ( bool disposing )
Original file line number Diff line number Diff line change 22
33## Unreleased
44
5- * Changed ` ActivityProcessor.OnShutdown ` and ` ActivityProcessor.Shutdown ` to
6- return boolean value
5+ * Changed ` ActivityExporter.OnShutdown ` , ` ActivityExporter.Shutdown ` ,
6+ ` ActivityProcessor.OnShutdown ` and ` ActivityProcessor.Shutdown ` to return
7+ boolean value
78 ([ #1282 ] ( https://github.com/open-telemetry/opentelemetry-dotnet/pull/1282 ) )
9+ ([ #1285 ] ( https://github.com/open-telemetry/opentelemetry-dotnet/pull/1285 ) )
810
911## 0.6.0-beta.1
1012
Original file line number Diff line number Diff line change @@ -83,8 +83,7 @@ public bool Shutdown(int timeoutMilliseconds = Timeout.Infinite)
8383
8484 try
8585 {
86- this . OnShutdown ( timeoutMilliseconds ) ;
87- return true ; // TODO: update exporter.OnShutdown to return boolean
86+ return this . OnShutdown ( timeoutMilliseconds ) ;
8887 }
8988 catch ( Exception ex )
9089 {
@@ -108,13 +107,17 @@ public void Dispose()
108107 /// The number of milliseconds to wait, or <c>Timeout.Infinite</c> to
109108 /// wait indefinitely.
110109 /// </param>
110+ /// <returns>
111+ /// Returns <c>true</c> when shutdown succeeded; otherwise, <c>false</c>.
112+ /// </returns>
111113 /// <remarks>
112114 /// This function is called synchronously on the thread which made the
113115 /// first call to <c>Shutdown</c>. This function should not throw
114116 /// exceptions.
115117 /// </remarks>
116- protected virtual void OnShutdown ( int timeoutMilliseconds )
118+ protected virtual bool OnShutdown ( int timeoutMilliseconds )
117119 {
120+ return true ;
118121 }
119122
120123 /// <summary>
You can’t perform that action at this time.
0 commit comments