Announcement Announcement Module
No announcement yet.
Wire tapping channel to do file logging? Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Wire tapping channel to do file logging?

    Is it possible to define a file logger as a wire tap interceptor with customized file logging like different file for error and debug? The current logging channel adapter logs it in the console.

  • #2
    Yes, define the interceptor, implement your logging logic and configure it to wire-tap on a particular channel or define it as global interceptor.


    • #3
      Thanks for the reply oleg.

      I wrote my own interceptor bean which extends ChannelInterceptorAdapter and overrides preSend method. Here I captured channel name from which the interceptor is invoked as I have single logging interceptor for all channels so I need to know the channel name for which the log message is generated. This was not available in the wire tap logging handler adapter provided in spring integration.

      Thanks anyways.