UNPKG

@uoa/lambda-tracing

Version:

Library for logging & distributed tracing in UoA Lambda projects

61 lines (43 loc) 2.41 kB
# Changelog ## 2.3.0 - Automatically decode response if Content-Encoding header is present. Supports gzip, br, and deflate encodings. ## 2.2.2 - Change behaviour for optional audit parameters. Instead of removing empty optional parameters, they will be present with a hyphen ("-"). ## 2.2.1 - Fix formatting in readme ## 2.2.0 - Added audit level to logger - The logger debug, info, warn, and error functions now require a string input ## 2.1.2 - Updated XML response parsing to include attribute tags ## 2.1.1 - Fixed issue where JSON requests & responses could only have content-type application/json. Will now parse request/response if content-type header includes "json" anywhere. If "json" is not present, it will check for "xml", then "image". If none are present, the raw string body will be used. ## 2.1.0 - Unexpected errors are now caught within the library. When this occurs, the request promise will reject with the error. - http response promises will now be rejected if the response code is not in the 2xx range - The response content-type header is now correctly checked to convert the response body. Previously the response transformation was checking the content-type header of the request. If the content-type header is not present, it will attempt to transform the response to JSON. - Added support for XML responses - these will be parsed to an object - Added support for Image responses - these will be parsed to a base64 string ## [Deprecated] 2.0.0, 2.0.1, 2.0.2 - Changes for Zipkin which have since been removed - Do not use these versions ## 1.6.0 - Fix error when logged message was undefined ## 1.5.0 - Generate a new span ID instead of using that of the incoming request. - Use the incoming request's span ID as the current span's parent span ID. ## 1.4.0 - Add support for 16 and 32 character trace IDs - Add function to allow getting and setting the X-B3-Info header ## 1.3.0 - Add optional port parameter to all functions in uoaHttps module. Defaults to 443 if not specified ## 1.2.0 - Fix newlines not logging correctly in logging module ## 1.1.1 - Update readme with information on Kong plugin requirements ## 1.1.0 - Add uoaHttps module to propagate tracing headers through http requests ## 1.0.1 - Fix formatting in readme ## 1.0.0 - Initial release with Lambda tracing & logging functionality