JavaRush
AI Academy
new
Promotion
Learning
Courses
Tasks
Quizzes
Games
Help
Schedule of nudges
Internship
Community
Users
Forum
Chat
Articles
Success stories
Activities
Reviews
Subscriptions
Light theme

Lectures

  • Reviews
  • About us
  • CS50
Start
Start learning
Start learning
  • My progress
  • Courses
  • Quest map
  • Lectures
  • Log levels and a minimal Logger

    Kotlin SELF
    60 level,0 lecture
    We break down why a bunch of println calls is still not logging, introduce the DEBUG/ INFO/ WARN/ ERROR levels, the concept of a minimum level ( minLevel), and build a minimal logger: enum class LogLevel, a single line format timestamp [ LEVEL ] message, filtering by importance (via ordinal or an explicit priority), wrapper methods debug/ info/ warn/ error, and common mistakes when introducing logging.
    Open
  • Log context: key-value fields and formatting

    Kotlin SELF
    60 level,1 lecture
    We break down how to turn “scattered lines” into readable logs: introduce context as key=value pairs, store it in Map<String, String>, format it via joinToString(), add context to the logger API ( Logger), and link events of a single operation using requestId. At the end: hands-on practice on a command handler and a list of typical mistakes.
    Open
  • Exceptions in logs

    Kotlin SELF
    60 level,2 lecture
    We break down how to log exceptions so that troubleshooting is fast and accurate: why printing only e . message is not enough, why you need a stack trace, and how to conveniently get it via stackTraceToString(). We learn how to extend Logger to handle Throwable, how to properly “wrap” errors while preserving the cause, how to choose a single responsibility boundary for logging, and how not to duplicate the same stack trace at every layer. Finally, we cover nuances of reading a stack trace and common mistakes.
    Open
  • Metrics: timings and counters

    Kotlin SELF
    60 level,3 lecture
    We cover basic observability in a console application: how metrics differ from logs, how to measure operation duration with measureTimeMillis, how not to smear timers all over the codebase, how to build counters with MutableMap, agree on key names ( "command.add.total"), and integrate timings/counters into command handling. At the end, there is a mini metrics report and a list of common mistakes.
    Open
  • Log noise and log safety: verbose, lazy DEBUG, and masking

    Kotlin SELF
    60 level,4 lecture
    We break down how to make logs useful instead of noisy: levels DEBUG/ INFO/ WARN/ ERROR, switching verbosity via the "--verbose" flag, and choosing minLevel. We learn how to write lazy debug (via a lambda) so we don’t pay for building messages when the level is off, and we add safe key=value context with automatic secret masking via maskSecret().
    Open
Learn
  • Registration
  • Java course
  • Help with tasks
  • Pricing
Community
  • Users
  • Articles
  • Forum
  • Chat
  • Success stories
  • Activities
Company
  • About us
  • Contacts
  • Reviews
  • FAQ
  • Support
JavaRushJavaRush — is an interactive online course for learning Java programming from scratch. It contains 1200 practical tasks with one-click solution checking, the necessary minimum of theory on Java basics, and motivating features that help you complete the course: games, quizzes, interesting projects and articles on effective learning and the career of a Java developer.
Follow us
Язык интерфейса
Русский
English
Українська
"Programmers are not born" © 2026 JavaRush
MastercardVisa
"Programmers are not born" © 2026 JavaRush