Results 1 to 2 of 2

Thread: Create one log file for each JMS message retrived

  1. #1
    Join Date
    Dec 2011
    Posts
    26

    Default Create one log file for each JMS message retrived

    Hi everybody!

    I'm developing a JMS consumer system and I'm using log4j. I would like create a log file for each message that my system listen, actually i would like that the file's name come from the header of the message retrieved.

    Can anybody help me?
    Thanks!

  2. #2
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,625

    Default

    Don't use log4j... Use SLF4J with Logback and you get that feature out of the box, the SiftingAppender. Set a MDC property configure appropriatly and you are good to go.
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •