@@ -239,7 +239,7 @@ to customise what is logged.
239
239
*/
240
240
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
241
241
242
- Logger log = LogManager.getLogger();
242
+ Logger log = LogManager.getLogger(App.class );
243
243
244
244
@Logging
245
245
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -256,7 +256,7 @@ to customise what is logged.
256
256
* /
257
257
public class AppLogEvent implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
258
258
259
- Logger log = LogManager.getLogger();
259
+ Logger log = LogManager.getLogger(AppLogEvent.class );
260
260
261
261
@Logging (logEvent = true)
262
262
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -315,7 +315,7 @@ You can set a Correlation ID using `correlationIdPath` attribute by passing a [J
315
315
*/
316
316
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
317
317
318
- Logger log = LogManager.getLogger();
318
+ Logger log = LogManager.getLogger(App.class );
319
319
320
320
@Logging(correlationIdPath = "/headers/my_request_id_header")
321
321
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -364,7 +364,7 @@ for known event sources, where either a request ID or X-Ray Trace ID are present
364
364
*/
365
365
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
366
366
367
- Logger log = LogManager.getLogger();
367
+ Logger log = LogManager.getLogger(App.class );
368
368
369
369
@Logging(correlationIdPath = CorrelationIdPathConstants.API_GATEWAY_REST)
370
370
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -417,7 +417,7 @@ You can append your own keys to your existing logs via `appendKey`.
417
417
*/
418
418
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
419
419
420
- Logger log = LogManager.getLogger();
420
+ Logger log = LogManager.getLogger(App.class );
421
421
422
422
@Logging(logEvent = true)
423
423
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -449,7 +449,7 @@ You can remove any additional key from entry using `LoggingUtils.removeKeys()`.
449
449
*/
450
450
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
451
451
452
- Logger log = LogManager.getLogger();
452
+ Logger log = LogManager.getLogger(App.class );
453
453
454
454
@Logging(logEvent = true)
455
455
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -484,7 +484,7 @@ this means that custom keys can be persisted across invocations. If you want all
484
484
*/
485
485
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
486
486
487
- Logger log = LogManager.getLogger();
487
+ Logger log = LogManager.getLogger(App.class );
488
488
489
489
@Logging(clearState = true)
490
490
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
@@ -545,7 +545,7 @@ specific fields from received event due to security.
545
545
*/
546
546
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
547
547
548
- Logger log = LogManager.getLogger();
548
+ Logger log = LogManager.getLogger(App.class );
549
549
550
550
static {
551
551
ObjectMapper objectMapper = new ObjectMapper();
@@ -575,7 +575,7 @@ via `samplingRate` attribute on annotation.
575
575
*/
576
576
public class App implements RequestHandler<APIGatewayProxyRequestEvent, APIGatewayProxyResponseEvent> {
577
577
578
- Logger log = LogManager.getLogger();
578
+ Logger log = LogManager.getLogger(App.class );
579
579
580
580
@Logging(samplingRate = 0.5)
581
581
public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
0 commit comments