Package st.orm

Annotation Interface SqlLog


@Retention(RUNTIME) @Target({METHOD,TYPE}) public @interface SqlLog
Annotation for capturing and logging SQL statements.

Applying this annotation at either the method or type level will intercept execution via the repository proxy, capturing and logging SQL statements.

When applied at the type level, the annotation affects all methods within the repository. Method-level annotations override type-level annotations.

Since:
1.9
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
    If true, SQL parameters are inlined into the logged SQL statements for better readability.
    Defines the logging level used when outputting captured SQL.
    Optional logger name.
  • Element Details

    • inlineParameters

      boolean inlineParameters
      If true, SQL parameters are inlined into the logged SQL statements for better readability.
      Default:
      false
    • level

      Defines the logging level used when outputting captured SQL. Defaults to INFO.
      Default:
      INFO
    • name

      String name
      Optional logger name. If empty, the repository interface name is used.
      Default:
      ""