Skip to content

Conversation

tcheeric
Copy link
Owner

Summary

  • replace Lombok @Log with @Slf4j
  • update logging statements to use slf4j
  • refine log messages for clarity

Testing

  • mvn -q verify (fails: EventTest.testNip05Validator)

https://chatgpt.com/codex/tasks/task_b_68880d48f8e88331b343109b0ff06150

@tcheeric tcheeric requested a review from Copilot July 29, 2025 16:57
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR switches the logging framework from Java util logging to SLF4J by updating imports, annotations, and log statements across the codebase. It replaces Lombok's @Log annotation with @Slf4j and migrates Java util logging syntax to SLF4J's parameterized logging format for better performance and clarity.

  • Replace Lombok @Log with @Slf4j annotations across all Java files
  • Convert Java util logging method calls to SLF4J syntax with parameterized messages
  • Remove Java util logging imports and related configuration code

Reviewed Changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
nostr-java-util/src/test/java/nostr/util/NostrUtilTest.java Updates test class to use SLF4J logging
nostr-java-util/src/main/java/nostr/util/validator/Nip05Validator.java Migrates validation logging to SLF4J with improved error handling
nostr-java-id/src/test/java/nostr/id/ZapReceiptEventTest.java Updates test class logging annotation
nostr-java-id/src/test/java/nostr/id/EventTest.java Updates test class logging annotation
nostr-java-id/src/test/java/nostr/id/EntityFactory.java Updates factory class logging annotations
nostr-java-id/src/main/java/nostr/id/Identity.java Updates identity class logging
nostr-java-examples/src/main/java/nostr/examples/NostrApiExamples.java Migrates example application logging and removes util logging configuration
nostr-java-examples/src/main/java/nostr/examples/FilterRelays.java Updates relay filtering logging
nostr-java-event/src/test/java/nostr/event/unit/*.java Updates all event unit test classes to use SLF4J
nostr-java-event/src/main/java/nostr/event/message/EventMessage.java Migrates event message logging
nostr-java-event/src/main/java/nostr/event/json/serializer/TagSerializer.java Updates tag serialization logging
nostr-java-event/src/main/java/nostr/event/json/codec/GenericTagDecoder.java Migrates tag decoder logging
nostr-java-event/src/main/java/nostr/event/impl/GenericEvent.java Updates generic event logging
nostr-java-event/src/main/java/nostr/event/entities/UserProfile.java Migrates user profile logging
nostr-java-crypto/src/main/java/nostr/crypto/nip44/EncryptedPayloads.java Updates encryption logging
nostr-java-base/src/main/java/nostr/base/Relay.java Adds new debug logging to relay creation
nostr-java-api/src/test/java/nostr/api/unit/*.java Updates API unit test classes
nostr-java-api/src/test/java/nostr/api/integration/ApiEventIT.java Updates integration test logging
nostr-java-api/src/main/java/nostr/api/NIP46.java Migrates NIP46 logging
nostr-java-api/src/main/java/nostr/api/NIP44.java Updates NIP44 logging
nostr-java-api/src/main/java/nostr/api/NIP04.java Adds debug logging to NIP04 operations

@@ -42,14 +41,13 @@
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.TimeUnit;
import java.util.logging.Level;
import java.util.logging.LogManager;
import lombok.extern.slf4j.Slf4j;
Copy link
Preview

Copilot AI Jul 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicate import: lombok.extern.slf4j.Slf4j is imported twice (lines 3 and 44). Remove the duplicate import on line 44.

Suggested change
import lombok.extern.slf4j.Slf4j;

Copilot uses AI. Check for mistakes.

@tcheeric tcheeric merged commit ff56a50 into develop Jul 29, 2025
@tcheeric tcheeric deleted the codex/switch-to-lombok-@slf4j-and-improve-logging branch July 29, 2025 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant