How to redirect EMS Java client trace to a file.

How to redirect EMS Java client trace to a file.

book

Article ID: KB0093823

calendar_today

Updated On:

Products Versions
TIBCO Enterprise Message Service -
Not Applicable -

Description

Description:
EMS client trace is by default sent to STDERR. There are two approaches that can be used to have the client trace written to a file.

Issue/Introduction

How to redirect EMS Java client trace to a file.

Resolution

1) Programmatically, you can call Tibjms.setTraceFile() with the fileName from your application code. However, this is not practical since in most cases the client application is not a simple Java client that can be changed as needed.

2). Set the JVM property -Dtibco.tibjms.trace.file .


Example: java -Dtibco.tibjms.trace.file=/tmp/trace tibjmsMsgConsumer 


This will redirect the client trace to /tmp/trace file.