[jira] Created: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
28 messages Options
12
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12453674 ]
           
Chris Howe commented on OFBIZ-361:
----------------------------------

You're correct David, that syntax doesn't work in the screen widget (I can't confirm whether it works in platform-specific either even with an escaped curly brace).

using platform-specific and having a simple ftl file that only has

${logFileContent}

does actually work correctly.  No need to replace the ${

The error is that screen widget will process the ${screen.render...} and return nothing.  However, when run in freemarker, it does not try to process the string's ${..}

> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12453832 ]
           
Jacopo Cappellato commented on OFBIZ-361:
-----------------------------------------

Chris's last comment is good... using a freemarker template seems to have solved the issue.
No I have one last (I hope) question for you!
In the action tag of the screen definition for the viewLog page I set the path to the log file to display in the following way:

<property-to-field resource="debug" property="debug.log4j.appender.file.File" field="logFileName" default="framework/logs/ofbiz.log" no-locale="true"/>

However the file is not found and so the default value "framework/logs/ofbiz.log" is always used... am I doing something wrong?

THANKS



> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12453834 ]
           
Chris Howe commented on OFBIZ-361:
----------------------------------

your property attribute is incorrect. there is no "debug.log4j.appender.file.File" it should simply be "log4j.appender.file.File".

that should probably be set by variable as well for flexibility property="${parameters.fileProperty}" so that it can be set from the screen that calls it, which in turn could be set from a form later.

> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12453835 ]
           
Jacopo Cappellato commented on OFBIZ-361:
-----------------------------------------

Chris,

you are right (and I am an idiot)!! The property name was wrong... well I will not tell you how much time I've spent trying to understand why the command was not working....
About the variable thing... you are probably right too but for now I'd prefer to leave things simple.

Again, thanks

PS: is it ok if I commit the new log4j.appender.html definition for the debug.properties file?



> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12453837 ]
           
Chris Howe commented on OFBIZ-361:
----------------------------------

I would vote yes for committing the debug.properties with one change.  change the appender name from html to css.  

log4j.rootLogger= ..change the "html" to "css" (no quotes)

log4j.appender.  ... change all "html" to "css" (no quotes)

The reasoning for this is that there is a org.apache.log4j.HTMLLayout formatter that will print the log to an html table.  using the name css would avoid confusion as this logger is using the org.apache.log4j.PatternLayout

> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-361?page=all ]

Jacopo Cappellato updated OFBIZ-361:
------------------------------------

    Attachment: log.patch

This is the patch I'd like to commit soon (today or tomorrow) to improve the output of the view log screen; is it ok for all?


> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: log.patch, LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-361?page=comments#action_12454930 ]
           
Chris Howe commented on OFBIZ-361:
----------------------------------

For the css style sheet, instead of including it in maincss.css,  create a debug.css and include it in the following manner.


add this to the screen definition
        <set field="layoutSettings.styleSheets[]" value="/images/maincss.css"/>
        <set field="layoutSettings.styleSheets[]" value="/images/tabstyles.css"/>
        <set field="layoutSettings.styleSheets[]" value="/images/debug.css"/>


there may need to be a slight adjustment to /webcommon/includes/header.ftl.  I remember doing something to it, but can't remember exactly what it is right now.


> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: log.patch, LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-361) Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-361?page=all ]

Jacopo Cappellato closed OFBIZ-361.
-----------------------------------

    Resolution: Fixed

rev. 481544

> Migrate webtools debug level screens to widget and add dynamic configuration of log4j loggers
> ---------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-361
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-361
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: New Feature
>          Components: framework
>         Environment: Linux, sun-jdk-1.5.0
>            Reporter: Peter Goron
>         Assigned To: Jacopo Cappellato
>            Priority: Minor
>             Fix For: SVN trunk
>
>         Attachments: log.patch, LogConfiguration.png, webtools-debugging-screens-2.patch, webtools-debugging-screens.patch
>
>
> I was looking for a way to modify logging system without having to restart ofbiz. So I've enhanced debug level webtools screen to be able to add new loggers and change logging level of existing ones during ofbiz execution.
> In the same time, I've switched this screen from regions to screen and form widgets.
> See attached screenshot.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
12