<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Arial; font-size: 12pt; color: #000000'>So, that Attribute.FILE_NAME should actually be removed. At that point, its not really a set anymore, since the async-handler tag only requires the name attribute.<br><br>Andy<br><br><hr id="zwchr"><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; color: rgb(0, 0, 0); font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>From: </b>"Ales Justin" <ales.justin@gmail.com><br><b>To: </b>"Andrig Miller" <anmiller@redhat.com><br><b>Cc: </b>"jboss-as7-dev" <jboss-as7-dev@lists.jboss.org><br><b>Sent: </b>Thursday, June 23, 2011 9:29:57 AM<br><b>Subject: </b>Re: [jboss-as7-dev] Question about Async logging<br><br>Looking at the code, I would say that's a bug.<div><br></div><div><div> final EnumSet<Attribute> required = EnumSet.of(Attribute.FILE_NAME, <a href="http://Attribute.NAME" target="_blank">Attribute.NAME</a>);</div><div> final int count = reader.getAttributeCount();</div><div> for (int i = 0; i < count; i++) {</div><div> requireNoNamespaceAttribute(reader, i);</div><div> final String value = reader.getAttributeValue(i);</div><div> final Attribute attribute = Attribute.forName(reader.getAttributeLocalName(i));</div><div> required.remove(attribute);</div><div> switch (attribute) {</div><div> case NAME: {</div><div> name = value;</div><div> break;</div><div> }</div><div> default:</div><div> throw unexpectedAttribute(reader, i);</div><div> }</div><div> }</div><div> if (!required.isEmpty()) {</div><div> throw missingRequired(reader, required);</div><div> }</div></div><div><br></div><div>Since as you can see, FILE_NAME' value (if present) is never actually used / handled.</div><div><br><div><div>On Jun 23, 2011, at 8:22 AM, Andrig Miller wrote:</div><br class="Apple-interchange-newline"><blockquote><div><div style="font-family: Arial; font-size: 12pt; color: rgb(0, 0, 0);">I have looked over the JBoss logging XSD, and believe I have configured asynchronous logging correctly, but I'm getting a parse error.<br><br>Here is my configuration:<br><br><subsystem xmlns="urn:jboss:domain:logging:1.0"><br> <periodic-rotating-file-handler name="FILE" autoflush="true"><br> <level name="INFO"/><br> <formatter><br> <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/><br> </formatter><br> <file relative-to="jboss.server.log.dir" path="server.log"/><br> <suffix value=".yyyy-MM-dd"/><br> </periodic-rotating-file-handler><br> <async-handler name="ASYNC"><br> <level name="INFO"/><br> <queue-length>1024</queue-length><br> <overflow-action>block</overflow-action><br> <subhandlers>FILE</subhandlers><br> </async-handler><br> <logger category="com.arjuna"><br> <level name="WARN"/><br> </logger><br> <logger category="org.apache.tomcat.util.modeler"><br> <level name="WARN"/><br> </logger><br> <logger category="sun.rmi"><br> <level name="WARN"/><br> </logger><br> <root-logger><br> <level name="INFO"/><br> <handlers><br> <handler name="ASYNC"/><br> </handlers><br> </root-logger><br> </subsystem><br><br>Here is the exception:<br><br>Caused by: javax.xml.stream.XMLStreamException: ParseError at [row,col]:[51,13]<br>Message: Missing required attribute(s): FILE_NAME<br> at org.jboss.as.controller.parsing.ParseUtils.missingRequired(ParseUtils.java:115)<br> at org.jboss.as.logging.LoggingSubsystemParser.parseAsyncHandlerElement(LoggingSubsystemParser.java:259)<br> at org.jboss.as.logging.LoggingSubsystemParser.readElement(LoggingSubsystemParser.java:149)<br> at org.jboss.as.logging.LoggingSubsystemParser.readElement(LoggingSubsystemParser.java:84)<br> at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:100)<br> at org.jboss.staxmapper.XMLExtendedStreamReaderImpl.handleAny(XMLExtendedStreamReaderImpl.java:69)<br> at org.jboss.as.controller.parsing.StandaloneXml.parseServerProfile(StandaloneXml.java:309)<br> at org.jboss.as.controller.parsing.StandaloneXml.readServerElement(StandaloneXml.java:163)<br> at org.jboss.as.controller.parsing.StandaloneXml.readElement(StandaloneXml.java:87)<br> at org.jboss.as.controller.parsing.StandaloneXml.readElement(StandaloneXml.java:75)<br> at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:100)<br> at org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:59)<br> at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:105)<br> ... 5 more<br><br>I far as I can see there is no FILE_NAME required attribute, and the line and column number it gives is the start of the async-handler tag in the configuration above.<br><br>Any ideas?<br><br>Thanks.<br><br>Andy<br></div>_______________________________________________<br>jboss-as7-dev mailing list<br><a href="mailto:jboss-as7-dev@lists.jboss.org" target="_blank">jboss-as7-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/jboss-as7-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/jboss-as7-dev</a><br></div></blockquote></div><br></div></blockquote><br></div></body></html>