[GLASSFISH-5922] V3 should output log message with ANSI escape sequence to generate colors Created: 05/Sep/08  Updated: 06/Mar/12

Status: Open
Project: glassfish
Component/s: logging
Affects Version/s: V3
Fix Version/s: not determined

Type: Improvement Priority: Major
Reporter: vivekp Assignee: naman_mehta
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: All
Platform: Linux

Attachments: PNG File ansilog.png    
Issuezilla Id: 5,922


Modern log generators output log messages using ANSI escape sequences so that
terminals (such as gnome-terminal) can display such log messages with the right
colours. For example, when a SERVER message is displayed, the SERVER would be
coloured read.

I will attach a screen shot where the Rails application log messages piped thru
the v3 logger appears color coded on Ubuntu gnome-terminal.

For example, here is the log message with the escape sequence characters:
INFO: Upload Create (0.002076) INSERT INTO "uploads"
("filename", "content_type", "size", "created_at", "updated_at")
VALUES('183.patch', 'text/x-patch', 1960, '2008-09-04 00:12:41', '2008-09-04
INFO: SQL (0.000380) SELECT
INFO: Redirected to http://localhost:8080/uploader/uploads
INFO: Completed in 0.05216 (19 reqs/sec) | DB: 0.00885 (16%) | 302 Found

see the "[4;35;1" sequences, these are ANSI escape sequences to generate colors.

Comment by vivekp [ 05/Sep/08 ]

Created an attachment (id=1766)
colored log

Comment by Tom Mueller [ 06/Mar/12 ]

Bulk update to change fix version to "not determined" for all issues still open but with a fix version for a released version.

Generated at Sun Dec 04 09:49:14 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.