<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Arial; font-size: 12pt; color: #000000'>Thanks Ales.<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" &lt;ales.justin@gmail.com&gt;<br><b>To: </b>"Andrig Miller" &lt;anmiller@redhat.com&gt;<br><b>Cc: </b>"jboss-as7-dev" &lt;jboss-as7-dev@lists.jboss.org&gt;<br><b>Sent: </b>Thursday, June 23, 2011 9:45:12 AM<br><b>Subject: </b>Re: [jboss-as7-dev] Question about Async logging<br><br>Fixed here:<div>*&nbsp;<a href="https://github.com/jbossas/jboss-as/pull/67" target="_blank">https://github.com/jbossas/jboss-as/pull/67</a></div><div><br><div><div>On Jun 23, 2011, at 8:36 AM, Andrig Miller wrote:</div><br class="Apple-interchange-newline"><blockquote><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; font-size: medium;"><div><div style="font-family: Arial; font-size: 12pt; color: rgb(0, 0, 0);">So, that Attribute.FILE_NAME should actually be removed.&nbsp; 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:<span class="Apple-converted-space">&nbsp;</span></b>"Ales Justin" &lt;<a href="mailto:ales.justin@gmail.com" target="_blank">ales.justin@gmail.com</a>&gt;<br><b>To:<span class="Apple-converted-space">&nbsp;</span></b>"Andrig Miller" &lt;<a href="mailto:anmiller@redhat.com" target="_blank">anmiller@redhat.com</a>&gt;<br><b>Cc:<span class="Apple-converted-space">&nbsp;</span></b>"jboss-as7-dev" &lt;<a href="mailto:jboss-as7-dev@lists.jboss.org" target="_blank">jboss-as7-dev@lists.jboss.org</a>&gt;<br><b>Sent:<span class="Apple-converted-space">&nbsp;</span></b>Thursday, June 23, 2011 9:29:57 AM<br><b>Subject:<span class="Apple-converted-space">&nbsp;</span></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>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;final EnumSet&lt;Attribute&gt; required = EnumSet.of(Attribute.FILE_NAME,<span class="Apple-converted-space">&nbsp;</span><a href="http://Attribute.NAME" target="_blank">Attribute.NAME</a>);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;final int count = reader.getAttributeCount();</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;for (int i = 0; i &lt; count; i++) {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;requireNoNamespaceAttribute(reader, i);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;final String value = reader.getAttributeValue(i);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;final Attribute attribute = Attribute.forName(reader.getAttributeLocalName(i));</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;required.remove(attribute);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;switch (attribute) {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;case NAME: {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;name = value;</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;break;</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;}</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;default:</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;throw unexpectedAttribute(reader, i);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;}</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;}</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;if (!required.isEmpty()) {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;throw missingRequired(reader, required);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;}</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>&lt;subsystem xmlns="urn:jboss:domain:logging:1.0"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;periodic-rotating-file-handler name="FILE" autoflush="true"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="INFO"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;formatter&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/formatter&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;file relative-to="jboss.server.log.dir" path="server.log"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;suffix value=".yyyy-MM-dd"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/periodic-rotating-file-handler&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;async-handler name="ASYNC"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="INFO"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;queue-length&gt;1024&lt;/queue-length&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;overflow-action&gt;block&lt;/overflow-action&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;subhandlers&gt;FILE&lt;/subhandlers&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/async-handler&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;logger category="com.arjuna"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="WARN"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/logger&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;logger category="org.apache.tomcat.util.modeler"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="WARN"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/logger&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;logger category="sun.rmi"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="WARN"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/logger&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;root-logger&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;level name="INFO"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;handlers&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;handler name="ASYNC"/&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/handlers&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/root-logger&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/subsystem&gt;<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>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.parsing.ParseUtils.missingRequired(ParseUtils.java:115)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.logging.LoggingSubsystemParser.parseAsyncHandlerElement(LoggingSubsystemParser.java:259)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.logging.LoggingSubsystemParser.readElement(LoggingSubsystemParser.java:149)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.logging.LoggingSubsystemParser.readElement(LoggingSubsystemParser.java:84)<br>&nbsp;&nbsp;&nbsp; at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:100)<br>&nbsp;&nbsp;&nbsp; at org.jboss.staxmapper.XMLExtendedStreamReaderImpl.handleAny(XMLExtendedStreamReaderImpl.java:69)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.parsing.StandaloneXml.parseServerProfile(StandaloneXml.java:309)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.parsing.StandaloneXml.readServerElement(StandaloneXml.java:163)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.parsing.StandaloneXml.readElement(StandaloneXml.java:87)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.parsing.StandaloneXml.readElement(StandaloneXml.java:75)<br>&nbsp;&nbsp;&nbsp; at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:100)<br>&nbsp;&nbsp;&nbsp; at org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:59)<br>&nbsp;&nbsp;&nbsp; at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:105)<br>&nbsp;&nbsp;&nbsp; ... 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></div></span><br class="Apple-interchange-newline"></blockquote></div><br></div></blockquote><br></div></body></html>