[ 
https://issues.apache.org/jira/browse/LOG4J2-1313?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15391365#comment-15391365
 ] 

Ralph Goers commented on LOG4J2-1313:
-------------------------------------

I doubt it. 

First, from what I can tell the PluginValue should be using the attribute if 
the XML node has no value.  But it is only checking for null. I am guessing it 
is an empty String.  

Second, I have a suspicion that "value" as an attribute might get treated 
incorrectly, but that is just based on a vague recollection.  You can certainly 
try it and see.  What is interesting is that although I am sure attributes can 
be specified as the value of an element the PluginAttributeVisitor is only 
looking at the attributes while PluginValueVisitor looks that the value of the 
node as well. This difference is why I suspect "value=" wouldn't work as a 
PluginAttribute.

> <Property name="" value="" /> not working
> -----------------------------------------
>
>                 Key: LOG4J2-1313
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-1313
>             Project: Log4j 2
>          Issue Type: Bug
>    Affects Versions: 2.5
>            Reporter: Philipp Knobel
>             Fix For: 2.7
>
>
> The documentation shows examples of the property tag like this 
> ([http://logging.apache.org/log4j/2.x/manual/configuration.html#ConfigurationSyntax]):
> {noformat}
> <Properties>
>     <Property name="name1">value</property>
>     <Property name="name2" value="value2"/>
>   </Properties>
> {noformat}
> When using the later one with the value attribute you'll get on startup this 
> error:
> {noformat}
> ERROR Property contains an invalid element or attribute "value"
> {noformat}
> It would be good to have the attribute support working as well, as otherwise 
> it might happen that IDE auto formatting is line breaking an attribute. If 
> this isn't possible please update the documentation.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to