Debian Codegraph @

CHANGELOG.md

raw
1 # CHANGELOG
2
3 **NOTE** Please see a module's release notes for change details.
4
5 ## v14.2.1
6
7 - In `Future.WaitForCompletionRef()`, if the initial async response includes a `Retry-After` header, sleep for the specified amount of time before starting to poll.
8 - Added `APIManagementHostManagementSuffix` field in Azure environment map.
9 - Added `SynapseEndpointSuffix` and `ResourceIdentifiers/Synapse` field in Azure environment map.
10
11 ## v14.2.0
12
13 - Added package comment to make `github.com/Azure/go-autorest` importable.
14
15 ## v14.1.1
16
17 ### Bug Fixes
18
19 - Change `x-ms-authorization-auxiliary` header value separator to comma.
20
21 ## v14.1.0
22
23 ### New Features
24
25 - Added `azure.SetEnvironment()` that will update the global environments map with the specified values.
26
27 ## v14.0.1
28
29 ### Bug Fixes
30
31 - Fix race condition when refreshing token.
32 - Fixed some tests to work with Go 1.14.
33
34 ## v14.0.0
35
36 ## Breaking Changes
37
38 - By default, the `DoRetryForStatusCodes` functions will no longer infinitely retry a request when the response returns an HTTP status code of 429 (StatusTooManyRequests). To opt in to the old behavior set `autorest.Count429AsRetry` to `false`.
39
40 ## New Features
41
42 - Variable `autorest.Max429Delay` can be used to control the maximum delay between retries when a 429 is received with no `Retry-After` header. The default is zero which means there is no cap.
43
44 ## v13.4.0
45
46 ## New Features
47
48 - Added field `SendDecorators` to the `Client` type. This can be used to specify a custom chain of SendDecorators per client.
49 - Added method `Client.Send()` which includes logic for selecting the preferred chain of SendDecorators.
50
51 ## v13.3.3
52
53 ### Bug Fixes
54
55 - Fixed connection leak when retrying requests.
56 - Enabled exponential back-off with a 2-minute cap when retrying on 429.
57 - Fixed some cases where errors were inadvertently dropped.
58
59 ## v13.3.2
60
61 ### Bug Fixes
62
63 - Updated `autorest.AsStringSlice()` to convert slice elements to their string representation.
64
65 ## v13.3.1
66
67 - Updated external dependencies.
68
69 ### Bug Fixes
70
71 ## v13.3.0
72
73 ### New Features
74
75 - Added support for shared key and shared access signature token authorization.
76 - `autorest.NewSharedKeyAuthorizer()` and dependent types.
77 - `autorest.NewSASTokenAuthorizer()` and dependent types.
78 - Added `ServicePrincipalToken.SetCustomRefresh()` so a custom refresh function can be invoked when a token has expired.
79
80 ### Bug Fixes
81
82 - Fixed `cli.AccessTokensPath()` to respect `AZURE_CONFIG_DIR` when set.
83 - Support parsing error messages in XML responses.
84
85 ## v13.2.0
86
87 ### New Features
88
89 - Added the following functions to replace their versions that don't take a context.
90 - `adal.InitiateDeviceAuthWithContext()`
91 - `adal.CheckForUserCompletionWithContext()`
92 - `adal.WaitForUserCompletionWithContext()`
93
94 ## v13.1.0
95
96 ### New Features
97
98 - Added support for MSI authentication on Azure App Service and Azure Functions.
99
100 ## v13.0.2
101
102 ### Bug Fixes
103
104 - Always retry a request even if the sender returns a non-nil error.
105
106 ## v13.0.1
107
108 ## Bug Fixes
109
110 - Fixed `autorest.WithQueryParameters()` so that it properly encodes multi-value query parameters.
111
112 ## v13.0.0
113
114 ## Breaking Changes
115
116 The `tracing` package has been rewritten to provide a common interface for consumers to wire in the tracing package of their choice.
117 What this means is that by default no tracing provider will be compiled into your program and setting the `AZURE_SDK_TRACING_ENABLED`
118 environment variable will have no effect. To enable this previous behavior you must now add the following import to your source file.
119 ```go
120 import _ "github.com/Azure/go-autorest/tracing/opencensus"
121 ```
122 The APIs required by autorest-generated code have remained but some APIs have been removed and new ones added.
123 The following APIs and variables have been removed (the majority of them were moved to the `opencensus` package).
124 - tracing.Transport
125 - tracing.Enable()
126 - tracing.EnableWithAIForwarding()
127 - tracing.Disable()
128
129 The following APIs and types have been added
130 - tracing.Tracer
131 - tracing.Register()
132
133 To hook up a tracer simply call `tracing.Register()` passing in a type that satisfies the `tracing.Tracer` interface.
134
135 ## v12.4.3
136
137 ### Bug Fixes
138
139 - `autorest.MultiTenantServicePrincipalTokenAuthorizer` will now properly add its auxiliary bearer tokens.
140
141 ## v12.4.2
142
143 ### Bug Fixes
144
145 - Improvements to the fixes made in v12.4.1.
146 - Remove `override` stanza from Gopkg.toml and `replace` directive from go.mod as they don't apply when being consumed as a dependency.
147 - Switched to latest version of `ocagent` that still depends on protobuf v1.2.
148 - Add indirect dependencies to the `required` clause with matching `constraint` stanzas so that `dep` dependencies match go.sum.
149
150 ## v12.4.1
151
152 ### Bug Fixes
153
154 - Updated OpenCensus and OCAgent versions to versions that don't depend on v1.3+ of protobuf as it was breaking kubernetes.
155 - Pinned opencensus-proto to a version that's compatible with our versions of OpenCensus and OCAgent.
156
157 ## v12.4.0
158
159 ### New Features
160
161 - Added `autorest.WithPrepareDecorators` and `autorest.GetPrepareDecorators` for adding and retrieving a custom chain of PrepareDecorators to the provided context.
162
163 ## v12.3.0
164
165 ### New Features
166
167 - Support for multi-tenant via x-ms-authorization-auxiliary header has been added for client credentials with
168 secret scenario; this basically bundles multiple OAuthConfig and ServicePrincipalToken types into corresponding
169 MultiTenant* types along with a new authorizer that adds the primary and auxiliary token headers to the reqest.
170 The authenticaion helpers have been updated to support this scenario; if environment var AZURE_AUXILIARY_TENANT_IDS
171 is set with a semicolon delimited list of tenants the multi-tenant codepath will kick in to create the appropriate authorizer.
172 See `adal.NewMultiTenantOAuthConfig`, `adal.NewMultiTenantServicePrincipalToken` and `autorest.NewMultiTenantServicePrincipalTokenAuthorizer`
173 along with their supporting types and methods.
174 - Added `autorest.WithSendDecorators` and `autorest.GetSendDecorators` for adding and retrieving a custom chain of SendDecorators to the provided context.
175 - Added `autorest.DoRetryForStatusCodesWithCap` and `autorest.DelayForBackoffWithCap` to enforce an upper bound on the duration between retries.
176
177 ## v12.2.0
178
179 ### New Features
180
181 - Added `autorest.WithXML`, `autorest.AsMerge`, `autorest.WithBytes` preparer decorators.
182 - Added `autorest.ByUnmarshallingBytes` response decorator.
183 - Added `Response.IsHTTPStatus` and `Response.HasHTTPStatus` helper methods for inspecting HTTP status code in `autorest.Response` types.
184
185 ### Bug Fixes
186
187 - `autorest.DelayWithRetryAfter` now supports HTTP-Dates in the `Retry-After` header and is not limited to just 429 status codes.
188
189 ## v12.1.0
190
191 ### New Features
192
193 - Added `to.ByteSlicePtr()`.
194 - Added blob/queue storage resource ID to `azure.ResourceIdentifier`.
195
196 ## v12.0.0
197
198 ### Breaking Changes
199
200 In preparation for modules the following deprecated content has been removed.
201
202 - async.NewFuture()
203 - async.Future.Done()
204 - async.Future.WaitForCompletion()
205 - async.DoPollForAsynchronous()
206 - The `utils` package
207 - validation.NewErrorWithValidationError()
208 - The `version` package
209
210 ## v11.9.0
211
212 ### New Features
213
214 - Add `ResourceIdentifiers` field to `azure.Environment` containing resource IDs for public and sovereign clouds.
215
216 ## v11.8.0
217
218 ### New Features
219
220 - Added `autorest.NewClientWithOptions()` to support endpoints that require free renegotiation.
221
222 ## v11.7.1
223
224 ### Bug Fixes
225
226 - Fix missing support for http(s) proxy when using the default sender.
227
228 ## v11.7.0
229
230 ### New Features
231
232 - Added methods to obtain a ServicePrincipalToken on the various credential configuration types in the `auth` package.
233
234 ## v11.6.1
235
236 ### Bug Fixes
237
238 - Fix ACR DNS endpoint for government clouds.
239 - Add Cosmos DB DNS endpoints.
240 - Update dependencies to resolve build breaks in OpenCensus.
241
242 ## v11.6.0
243
244 ### New Features
245
246 - Added type `autorest.BasicAuthorizer` to support Basic authentication.
247
248 ## v11.5.2
249
250 ### Bug Fixes
251
252 - Fixed `GetTokenFromCLI` did not work with zsh.
253
254 ## v11.5.1
255
256 ### Bug Fixes
257
258 - In `Client.sender()` set the minimum TLS version on HTTP clients to 1.2.
259
260 ## v11.5.0
261
262 ### New Features
263
264 - The `auth` package has been refactored so that the environment and file settings are now available.
265 - The methods used in `auth.NewAuthorizerFromEnvironment()` are now exported so that custom authorization chains can be created.
266 - Added support for certificate authorization for file-based config.
267
268 ## v11.4.0
269
270 ### New Features
271
272 - Added `adal.AddToUserAgent()` so callers can append custom data to the user-agent header used for ADAL requests.
273 - Exported `adal.UserAgent()` for parity with `autorest.Client`.
274
275 ## v11.3.2
276
277 ### Bug Fixes
278
279 - In `Future.WaitForCompletionRef()` if the provided context has a deadline don't add the default deadline.
280
281 ## v11.3.1
282
283 ### Bug Fixes
284
285 - For an LRO PUT operation the final GET URL was incorrectly set to the Location polling header in some cases.
286
287 ## v11.3.0
288
289 ### New Features
290
291 - Added method `ServicePrincipalToken()` to `DeviceFlowConfig` type.
292
293 ## v11.2.8
294
295 ### Bug Fixes
296
297 - Deprecate content in the `version` package. The functionality has been superseded by content in the `autorest` package.
298
299 ## v11.2.7
300
301 ### Bug Fixes
302
303 - Fix environment variable name for enabling tracing from `AZURE_SDK_TRACING_ENABELD` to `AZURE_SDK_TRACING_ENABLED`.
304 Note that for backward compatibility reasons, both will work until the next major version release of the package.
305
306 ## v11.2.6
307
308 ### Bug Fixes
309
310 - If zero bytes are read from a polling response body don't attempt to unmarshal them.
311
312 ## v11.2.5
313
314 ### Bug Fixes
315
316 - Removed race condition in `autorest.DoRetryForStatusCodes`.
317
318 ## v11.2.4
319
320 ### Bug Fixes
321
322 - Function `cli.ProfilePath` now respects environment `AZURE_CONFIG_DIR` if available.
323
324 ## v11.2.1
325
326 NOTE: Versions of Go prior to 1.10 have been removed from CI as they no
327 longer work with golint.
328
329 ### Bug Fixes
330
331 - Method `MSIConfig.Authorizer` now supports user-assigned identities.
332 - The adal package now reports its own user-agent string.
333
334 ## v11.2.0
335
336 ### New Features
337
338 - Added `tracing` package that enables instrumentation of HTTP and API calls.
339 Setting the env variable `AZURE_SDK_TRACING_ENABLED` or calling `tracing.Enable`
340 will start instrumenting the code for metrics and traces.
341 Additionally, setting the env variable `OCAGENT_TRACE_EXPORTER_ENDPOINT` or
342 calling `tracing.EnableWithAIForwarding` will start the instrumentation and connect to an
343 App Insights Local Forwarder that is needs to be running. Note that if the
344 AI Local Forwarder is not running tracking will still be enabled.
345 By default, instrumentation is disabled. Once enabled, instrumentation can also
346 be programatically disabled by calling `Disable`.
347 - Added `DoneWithContext` call for checking LRO status. `Done` has been deprecated.
348
349 ### Bug Fixes
350
351 - Don't use the initial request's context for LRO polling.
352 - Don't override the `refreshLock` and the `http.Client` when unmarshalling `ServicePrincipalToken` if
353 it is already set.
354
355 ## v11.1.1
356
357 ### Bug Fixes
358
359 - When creating a future always include the polling tracker even if there's a failure; this allows the underlying response to be obtained by the caller.
360
361 ## v11.1.0
362
363 ### New Features
364
365 - Added `auth.NewAuthorizerFromCLI` to create an authorizer configured from the Azure 2.0 CLI.
366 - Added `adal.NewOAuthConfigWithAPIVersion` to create an OAuthConfig with the specified API version.
367
368 ## v11.0.1
369
370 ### New Features
371
372 - Added `x5c` header to client assertion for certificate Issuer+Subject Name authentication.
373
374 ## v11.0.0
375
376 ### Breaking Changes
377
378 - To handle differences between ADFS and AAD the following fields have had their types changed from `string` to `json.Number`
379 - ExpiresIn
380 - ExpiresOn
381 - NotBefore
382
383 ### New Features
384
385 - Added `auth.NewAuthorizerFromFileWithResource` to create an authorizer from the config file with the specified resource.
386 - Setting a client's `PollingDuration` to zero will use the provided context to control a LRO's polling duration.
387
388 ## v10.15.5
389
390 ### Bug Fixes
391
392 - In `DoRetryForStatusCodes`, if a request's context is cancelled return the last response.
393
394 ## v10.15.4
395
396 ### Bug Fixes
397
398 - If a polling operation returns a failure status code return the associated error.
399
400 ## v10.15.3
401
402 ### Bug Fixes
403
404 - Initialize the polling URL and method for an LRO tracker on each iteration, favoring the Azure-AsyncOperation header.
405
406 ## v10.15.2
407
408 ### Bug Fixes
409
410 - Use fmt.Fprint when printing request/response so that any escape sequences aren't treated as format specifiers.
411
412 ## v10.15.1
413
414 ### Bug Fixes
415
416 - If an LRO API returns a `Failed` provisioning state in the initial response return an error at that point so the caller doesn't have to poll.
417 - For failed LROs without an OData v4 error include the response body in the error's `AdditionalInfo` field to aid in diagnosing the failure.
418
419 ## v10.15.0
420
421 ### New Features
422
423 - Add initial support for request/response logging via setting environment variables.
424 Setting `AZURE_GO_SDK_LOG_LEVEL` to `LogInfo` will log request/response
425 without their bodies. To include the bodies set the log level to `LogDebug`.
426 By default the logger writes to strerr, however it can also write to stdout or a file
427 if specified in `AZURE_GO_SDK_LOG_FILE`. Note that if the specified file
428 already exists it will be truncated.
429 IMPORTANT: by default the logger will redact the Authorization and Ocp-Apim-Subscription-Key
430 headers. Any other secrets will _not_ be redacted.
431
432 ## v10.14.0
433
434 ### New Features
435
436 - Added package version that contains version constants and user-agent data.
437
438 ### Bug Fixes
439
440 - Add the user-agent to token requests.
441
442 ## v10.13.0
443
444 - Added support for additionalInfo in ServiceError type.
445
446 ## v10.12.0
447
448 ### New Features
449
450 - Added field ServicePrincipalToken.MaxMSIRefreshAttempts to configure the maximun number of attempts to refresh an MSI token.
451
452 ## v10.11.4
453
454 ### Bug Fixes
455
456 - If an LRO returns http.StatusOK on the initial response with no async headers return the response body from Future.GetResult().
457 - If there is no "final GET URL" return an error from Future.GetResult().
458
459 ## v10.11.3
460
461 ### Bug Fixes
462
463 - In IMDS retry logic, if we don't receive a response don't retry.
464 - Renamed the retry function so it's clear it's meant for IMDS only.
465 - For error response bodies that aren't OData-v4 compliant stick the raw JSON in the ServiceError.Details field so the information isn't lost.
466 - Also add the raw HTTP response to the DetailedResponse.
467 - Removed superfluous wrapping of response error in azure.DoRetryWithRegistration().
468
469 ## v10.11.2
470
471 ### Bug Fixes
472
473 - Validation for integers handles int and int64 types.
474
475 ## v10.11.1
476
477 ### Bug Fixes
478
479 - Adding User information to authorization config as parsed from CLI cache.
480
481 ## v10.11.0
482
483 ### New Features
484
485 - Added NewServicePrincipalTokenFromManualTokenSecret for creating a new SPT using a manual token and secret
486 - Added method ServicePrincipalToken.MarshalTokenJSON() to marshall the inner Token
487
488 ## v10.10.0
489
490 ### New Features
491
492 - Most ServicePrincipalTokens can now be marshalled/unmarshall to/from JSON (ServicePrincipalCertificateSecret and ServicePrincipalMSISecret are not supported).
493 - Added method ServicePrincipalToken.SetRefreshCallbacks().
494
495 ## v10.9.2
496
497 ### Bug Fixes
498
499 - Refreshing a refresh token obtained from a web app authorization code now works.
500
501 ## v10.9.1
502
503 ### Bug Fixes
504
505 - The retry logic for MSI token requests now uses exponential backoff per the guidelines.
506 - IsTemporaryNetworkError() will return true for errors that don't implement the net.Error interface.
507
508 ## v10.9.0
509
510 ### Deprecated Methods
511
512 | Old Method | New Method |
513 | -------------------------: | :---------------------------: |
514 | azure.NewFuture() | azure.NewFutureFromResponse() |
515 | Future.WaitForCompletion() | Future.WaitForCompletionRef() |
516
517 ### New Features
518
519 - Added azure.NewFutureFromResponse() for creating a Future from the initial response from an async operation.
520 - Added Future.GetResult() for making the final GET call to retrieve the result from an async operation.
521
522 ### Bug Fixes
523
524 - Some futures failed to return their results, this should now be fixed.
525
526 ## v10.8.2
527
528 ### Bug Fixes
529
530 - Add nil-gaurd to token retry logic.
531
532 ## v10.8.1
533
534 ### Bug Fixes
535
536 - Return a TokenRefreshError if the sender fails on the initial request.
537 - Don't retry on non-temporary network errors.
538
539 ## v10.8.0
540
541 - Added NewAuthorizerFromEnvironmentWithResource() helper function.
542
543 ## v10.7.0
544
545 ### New Features
546
547 - Added \*WithContext() methods to ADAL token refresh operations.
548
549 ## v10.6.2
550
551 - Fixed a bug on device authentication.
552
553 ## v10.6.1
554
555 - Added retries to MSI token get request.
556
557 ## v10.6.0
558
559 - Changed MSI token implementation. Now, the token endpoint is the IMDS endpoint.
560
561 ## v10.5.1
562
563 ### Bug Fixes
564
565 - `DeviceFlowConfig.Authorizer()` now prints the device code message when running `go test`. `-v` flag is required.
566
567 ## v10.5.0
568
569 ### New Features
570
571 - Added NewPollingRequestWithContext() for use with polling asynchronous operations.
572
573 ### Bug Fixes
574
575 - Make retry logic use the request's context instead of the deprecated Cancel object.
576
577 ## v10.4.0
578
579 ### New Features
580
581 - Added helper for parsing Azure Resource ID's.
582 - Added deprecation message to utils.GetEnvVarOrExit()
583
584 ## v10.3.0
585
586 ### New Features
587
588 - Added EnvironmentFromURL method to load an Environment from a given URL. This function is particularly useful in the private and hybrid Cloud model, where one may define their own endpoints
589 - Added TokenAudience endpoint to Environment structure. This is useful in private and hybrid cloud models where TokenAudience endpoint can be different from ResourceManagerEndpoint
590
591 ## v10.2.0
592
593 ### New Features
594
595 - Added endpoints for batch management.
596
597 ## v10.1.3
598
599 ### Bug Fixes
600
601 - In Client.Do() invoke WithInspection() last so that it will inspect WithAuthorization().
602 - Fixed authorization methods to invoke p.Prepare() first, aligning them with the other preparers.
603
604 ## v10.1.2
605
606 - Corrected comment for auth.NewAuthorizerFromFile() function.
607
608 ## v10.1.1
609
610 - Updated version number to match current release.
611
612 ## v10.1.0
613
614 ### New Features
615
616 - Expose the polling URL for futures.
617
618 ### Bug Fixes
619
620 - Add validation.NewErrorWithValidationError back to prevent breaking changes (it is deprecated).
621
622 ## v10.0.0
623
624 ### New Features
625
626 - Added target and innererror fields to ServiceError to comply with OData v4 spec.
627 - The Done() method on futures will now return a ServiceError object when available (it used to return a partial value of such errors).
628 - Added helper methods for obtaining authorizers.
629 - Expose the polling URL for futures.
630
631 ### Bug Fixes
632
633 - Switched from glide to dep for dependency management.
634 - Fixed unmarshaling of ServiceError for JSON bodies that don't conform to the OData spec.
635 - Fixed a race condition in token refresh.
636
637 ### Breaking Changes
638
639 - The ServiceError.Details field type has been changed to match the OData v4 spec.
640 - Go v1.7 has been dropped from CI.
641 - API parameter validation failures will now return a unique error type validation.Error.
642 - The adal.Token type has been decomposed from adal.ServicePrincipalToken (this was necessary in order to fix the token refresh race).
643
644 ## v9.10.0
645
646 - Fix the Service Bus suffix in Azure public env
647 - Add Service Bus Endpoint (AAD ResourceURI) for use in [Azure Service Bus RBAC Preview](https://docs.microsoft.com/en-us/azure/service-bus-messaging/service-bus-role-based-access-control)
648
649 ## v9.9.0
650
651 ### New Features
652
653 - Added EventGridKeyAuthorizer for key authorization with event grid topics.
654
655 ### Bug Fixes
656
657 - Fixed race condition when auto-refreshing service principal tokens.
658
659 ## v9.8.1
660
661 ### Bug Fixes
662
663 - Added http.StatusNoContent (204) to the list of expected status codes for long-running operations.
664 - Updated runtime version info so it's current.
665
666 ## v9.8.0
667
668 ### New Features
669
670 - Added type azure.AsyncOpIncompleteError to be returned from a future's Result() method when the operation has not completed.
671
672 ## v9.7.1
673
674 ### Bug Fixes
675
676 - Use correct AAD and Graph endpoints for US Gov environment.
677
678 ## v9.7.0
679
680 ### New Features
681
682 - Added support for application/octet-stream MIME types.
683
684 ## v9.6.1
685
686 ### Bug Fixes
687
688 - Ensure Authorization header is added to request when polling for registration status.
689
690 ## v9.6.0
691
692 ### New Features
693
694 - Added support for acquiring tokens via MSI with a user assigned identity.
695
696 ## v9.5.3
697
698 ### Bug Fixes
699
700 - Don't remove encoding of existing URL Query parameters when calling autorest.WithQueryParameters.
701 - Set correct Content Type when using autorest.WithFormData.
702
703 ## v9.5.2
704
705 ### Bug Fixes
706
707 - Check for nil \*http.Response before dereferencing it.
708
709 ## v9.5.1
710
711 ### Bug Fixes
712
713 - Don't count http.StatusTooManyRequests (429) against the retry cap.
714 - Use retry logic when SkipResourceProviderRegistration is set to true.
715
716 ## v9.5.0
717
718 ### New Features
719
720 - Added support for username + password, API key, authoriazation code and cognitive services authentication.
721 - Added field SkipResourceProviderRegistration to clients to provide a way to skip auto-registration of RPs.
722 - Added utility function AsStringSlice() to convert its parameters to a string slice.
723
724 ### Bug Fixes
725
726 - When checking for authentication failures look at the error type not the status code as it could vary.
727
728 ## v9.4.2
729
730 ### Bug Fixes
731
732 - Validate parameters when creating credentials.
733 - Don't retry requests if the returned status is a 401 (http.StatusUnauthorized) as it will never succeed.
734
735 ## v9.4.1
736
737 ### Bug Fixes
738
739 - Update the AccessTokensPath() to read access tokens path through AZURE_ACCESS_TOKEN_FILE. If this
740 environment variable is not set, it will fall back to use default path set by Azure CLI.
741 - Use case-insensitive string comparison for polling states.
742
743 ## v9.4.0
744
745 ### New Features
746
747 - Added WaitForCompletion() to Future as a default polling implementation.
748
749 ### Bug Fixes
750
751 - Method Future.Done() shouldn't update polling status for unexpected HTTP status codes.
752
753 ## v9.3.1
754
755 ### Bug Fixes
756
757 - DoRetryForStatusCodes will retry if sender.Do returns a non-nil error.
758
759 ## v9.3.0
760
761 ### New Features
762
763 - Added PollingMethod() to Future so callers know what kind of polling mechanism is used.
764 - Added azure.ChangeToGet() which transforms an http.Request into a GET (to be used with LROs).
765
766 ## v9.2.0
767
768 ### New Features
769
770 - Added support for custom Azure Stack endpoints.
771 - Added type azure.Future used to track the status of long-running operations.
772
773 ### Bug Fixes
774
775 - Preserve the original error in DoRetryWithRegistration when registration fails.
776
777 ## v9.1.1
778
779 - Fixes a bug regarding the cookie jar on `autorest.Client.Sender`.
780
781 ## v9.1.0
782
783 ### New Features
784
785 - In cases where there is a non-empty error from the service, attempt to unmarshal it instead of uniformly calling it an "Unknown" error.
786 - Support for loading Azure CLI Authentication files.
787 - Automatically register your subscription with the Azure Resource Provider if it hadn't been previously.
788
789 ### Bug Fixes
790
791 - RetriableRequest can now tolerate a ReadSeekable body being read but not reset.
792 - Adding missing Apache Headers
793
794 ## v9.0.0
795
796 > **IMPORTANT:** This release was intially labeled incorrectly as `v8.4.0`. From the time it was released, it should have been marked `v9.0.0` because it contains breaking changes to the MSI packages. We appologize for any inconvenience this causes.
797
798 Adding MSI Endpoint Support and CLI token rehydration.
799
800 ## v8.3.1
801
802 Pick up bug fix in adal for MSI support.
803
804 ## v8.3.0
805
806 Updates to Error string formats for clarity. Also, adding a copy of the http.Response to errors for an improved debugging experience.
807
808 ## v8.2.0
809
810 ### New Features
811
812 - Add support for bearer authentication callbacks
813 - Support 429 response codes that include "Retry-After" header
814 - Support validation constraint "Pattern" for map keys
815
816 ### Bug Fixes
817
818 - Make RetriableRequest work with multiple versions of Go
819
820 ## v8.1.1
821
822 Updates the RetriableRequest to take advantage of GetBody() added in Go 1.8.
823
824 ## v8.1.0
825
826 Adds RetriableRequest type for more efficient handling of retrying HTTP requests.
827
828 ## v8.0.0
829
830 ADAL refactored into its own package.
831 Support for UNIX time.
832
833 ## v7.3.1
834
835 - Version Testing now removed from production bits that are shipped with the library.
836
837 ## v7.3.0
838
839 - Exposing new `RespondDecorator`, `ByDiscardingBody`. This allows operations
840 to acknowledge that they do not need either the entire or a trailing portion
841 of accepts response body. In doing so, Go's http library can reuse HTTP
842 connections more readily.
843 - Adding `PrepareDecorator` to target custom BaseURLs.
844 - Adding ACR suffix to public cloud environment.
845 - Updating Glide dependencies.
846
847 ## v7.2.5
848
849 - Fixed the Active Directory endpoint for the China cloud.
850 - Removes UTF-8 BOM if present in response payload.
851 - Added telemetry.
852
853 ## v7.2.3
854
855 - Fixing bug in calls to `DelayForBackoff` that caused doubling of delay
856 duration.
857
858 ## v7.2.2
859
860 - autorest/azure: added ASM and ARM VM DNS suffixes.
861
862 ## v7.2.1
863
864 - fixed parsing of UTC times that are not RFC3339 conformant.
865
866 ## v7.2.0
867
868 - autorest/validation: Reformat validation error for better error message.
869
870 ## v7.1.0
871
872 - preparer: Added support for multipart formdata - WithMultiPartFormdata()
873 - preparer: Added support for sending file in request body - WithFile
874 - client: Added RetryDuration parameter.
875 - autorest/validation: new package for validation code for Azure Go SDK.
876
877 ## v7.0.7
878
879 - Add trailing / to endpoint
880 - azure: add EnvironmentFromName
881
882 ## v7.0.6
883
884 - Add retry logic for 408, 500, 502, 503 and 504 status codes.
885 - Change url path and query encoding logic.
886 - Fix DelayForBackoff for proper exponential delay.
887 - Add CookieJar in Client.
888
889 ## v7.0.5
890
891 - Add check to start polling only when status is in [200,201,202].
892 - Refactoring for unchecked errors.
893 - azure/persist changes.
894 - Fix 'file in use' issue in renewing token in deviceflow.
895 - Store header RetryAfter for subsequent requests in polling.
896 - Add attribute details in service error.
897
898 ## v7.0.4
899
900 - Better error messages for long running operation failures
901
902 ## v7.0.3
903
904 - Corrected DoPollForAsynchronous to properly handle the initial response
905
906 ## v7.0.2
907
908 - Corrected DoPollForAsynchronous to continue using the polling method first discovered
909
910 ## v7.0.1
911
912 - Fixed empty JSON input error in ByUnmarshallingJSON
913 - Fixed polling support for GET calls
914 - Changed format name from TimeRfc1123 to TimeRFC1123
915
916 ## v7.0.0
917
918 - Added ByCopying responder with supporting TeeReadCloser
919 - Rewrote Azure asynchronous handling
920 - Reverted to only unmarshalling JSON
921 - Corrected handling of RFC3339 time strings and added support for Rfc1123 time format
922
923 The `json.Decoder` does not catch bad data as thoroughly as `json.Unmarshal`. Since
924 `encoding/json` successfully deserializes all core types, and extended types normally provide
925 their custom JSON serialization handlers, the code has been reverted back to using
926 `json.Unmarshal`. The original change to use `json.Decode` was made to reduce duplicate
927 code; there is no loss of function, and there is a gain in accuracy, by reverting.
928
929 Additionally, Azure services indicate requests to be polled by multiple means. The existing code
930 only checked for one of those (that is, the presence of the `Azure-AsyncOperation` header).
931 The new code correctly covers all cases and aligns with the other Azure SDKs.
932
933 ## v6.1.0
934
935 - Introduced `date.ByUnmarshallingJSONDate` and `date.ByUnmarshallingJSONTime` to enable JSON encoded values.
936
937 ## v6.0.0
938
939 - Completely reworked the handling of polled and asynchronous requests
940 - Removed unnecessary routines
941 - Reworked `mocks.Sender` to replay a series of `http.Response` objects
942 - Added `PrepareDecorators` for primitive types (e.g., bool, int32)
943
944 Handling polled and asynchronous requests is no longer part of `Client#Send`. Instead new
945 `SendDecorators` implement different styles of polled behavior. See`autorest.DoPollForStatusCodes`
946 and `azure.DoPollForAsynchronous` for examples.
947
948 ## v5.0.0
949
950 - Added new RespondDecorators unmarshalling primitive types
951 - Corrected application of inspection and authorization PrependDecorators
952
953 ## v4.0.0
954
955 - Added support for Azure long-running operations.
956 - Added cancelation support to all decorators and functions that may delay.
957 - Breaking: `DelayForBackoff` now accepts a channel, which may be nil.
958
959 ## v3.1.0
960
961 - Add support for OAuth Device Flow authorization.
962 - Add support for ServicePrincipalTokens that are backed by an existing token, rather than other secret material.
963 - Add helpers for persisting and restoring Tokens.
964 - Increased code coverage in the github.com/Azure/autorest/azure package
965
966 ## v3.0.0
967
968 - Breaking: `NewErrorWithError` no longer takes `statusCode int`.
969 - Breaking: `NewErrorWithStatusCode` is replaced with `NewErrorWithResponse`.
970 - Breaking: `Client#Send()` no longer takes `codes ...int` argument.
971 - Add: XML unmarshaling support with `ByUnmarshallingXML()`
972 - Stopped vending dependencies locally and switched to [Glide](https://github.com/Masterminds/glide).
973 Applications using this library should either use Glide or vendor dependencies locally some other way.
974 - Add: `azure.WithErrorUnlessStatusCode()` decorator to handle Azure errors.
975 - Fix: use `net/http.DefaultClient` as base client.
976 - Fix: Missing inspection for polling responses added.
977 - Add: CopyAndDecode helpers.
978 - Improved `./autorest/to` with `[]string` helpers.
979 - Removed golint suppressions in .travis.yml.
980
981 ## v2.1.0
982
983 - Added `StatusCode` to `Error` for more easily obtaining the HTTP Reponse StatusCode (if any)
984
985 ## v2.0.0
986
987 - Changed `to.StringMapPtr` method signature to return a pointer
988 - Changed `ServicePrincipalCertificateSecret` and `NewServicePrincipalTokenFromCertificate` to support generic certificate and private keys
989
990 ## v1.0.0
991
992 - Added Logging inspectors to trace http.Request / Response
993 - Added support for User-Agent header
994 - Changed WithHeader PrepareDecorator to use set vs. add
995 - Added JSON to error when unmarshalling fails
996 - Added Client#Send method
997 - Corrected case of "Azure" in package paths
998 - Added "to" helpers, Azure helpers, and improved ease-of-use
999 - Corrected golint issues
1000
1001 ## v1.0.1
1002
1003 - Added CHANGELOG.md
1004
1005 ## v1.1.0
1006
1007 - Added mechanism to retrieve a ServicePrincipalToken using a certificate-signed JWT
1008 - Added an example of creating a certificate-based ServicePrincipal and retrieving an OAuth token using the certificate
1009
1010 ## v1.1.1
1011
1012 - Introduce godeps and vendor dependencies introduced in v1.1.1