Skip to content
This repository has been archived by the owner on Mar 15, 2022. It is now read-only.

Unable to set filename for logging file handler in UI #65

Closed
sebasbaumh opened this issue Sep 1, 2015 · 7 comments
Closed

Unable to set filename for logging file handler in UI #65

sebasbaumh opened this issue Sep 1, 2015 · 7 comments

Comments

@sebasbaumh
Copy link

I am unable to set the filename of a file handler or periodic file handler in the UI:
2015-09-01_14-32-03

In the standalone.xml file I am able to actually configure a file like that:

            <periodic-rotating-file-handler name="FILE" autoflush="true">
                <formatter>
                    <named-formatter name="PATTERN"/>
                </formatter>
                <file relative-to="jboss.server.log.dir" path="server.log"/>
                <suffix value=".yyyy-MM-dd"/>
                <append value="true"/>
            </periodic-rotating-file-handler>

In the XML the suffix attribute looks pretty similar to file and is shown in the UI.
So I went through the source code starting from src.main.java.org.jboss.as.console.client.shared.subsys.logger.HandlerView, but I was not able to track the issue down further than that.

Expected behavior: A field to enter the filename should show up under attributes in the UI.
Used version: WildFly 9.0.1

@sebasbaumh
Copy link
Author

I just saw that the WildFly CLI command /subsystem=logging/periodic-rotating-file-handler= *:read-resource
returns that:

{
    "outcome" => "success",
    "result" => [
        {
            "address" => [
                ("subsystem" => "logging"),
                ("periodic-rotating-file-handler" => "FILE")
            ],
            "outcome" => "success",
            "result" => {
                "append" => true,
                "autoflush" => true,
                "enabled" => true,
                "encoding" => undefined,
                "file" => {
                    "relative-to" => "jboss.server.log.dir",
                    "path" => "server.log"
                },
                "filter" => undefined,
                "filter-spec" => undefined,
                "formatter" => "%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%e%n",
                "level" => "ALL",
                "name" => "FILE",
                "named-formatter" => "PATTERN",
                "suffix" => ".yyyy-MM-dd"
            }
        }
    ]
}

Maybe file showing up as a sub-node is the reason for not being listed below attributes?

@heiko-braun
Copy link
Contributor

yes, good catch. that's the reason.

currently complex attributes are not supported in the mode based form elements (generated from the management model meta data). but obviously a log handler without the ability to configure the file attribute doesn't make much sense :)

I'll revisit this next week.

@heiko-braun
Copy link
Contributor

@hpehl maybe we should make complex (nested) attributes addressable so that their contents can be edited like regular resources? The downside would be that any complex attribute would have to be moved to a custom form (and tab)

i.e.

/subsystem=logging/periodic-rotating-file-handler#file

@heiko-braun
Copy link
Contributor

@sebasbaumh btw, you try the latest WF 10 Beta1 console. It's basically the same, but much improved. Any feedback is greatly appreciated. See http://blog.arungupta.me/wildfly-admin-console-updated-feedback-requested/

@sebasbaumh
Copy link
Author

Thanks for looking at that issue.
I'll try the new beta console in the next days with the EAR, that I am building for my company.
The WildFly console is a great tool to allow administration of the server even for people without a deep knowledge of the XML configuration.

Maybe you can just show the contents of the complex type in another attribute form.
Or like in a small tree (inline), which can be expanded to configure the contents as an intended attribute list?

@heiko-braun
Copy link
Contributor

@heiko-braun
Copy link
Contributor

Please track the above issue. I am going to close this one.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants