[jira] [Comment Edited] (JCRVLT-391) Remove copied classes of Xerces

2019-11-29 Thread Konrad Windszus (Jira)


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

Konrad Windszus edited comment on JCRVLT-391 at 11/29/19 3:38 PM:
--

I made an attempt in https://github.com/apache/jackrabbit-filevault/pull/68. 
Some tests are still failing, but overall looks quite promising.
On question around linebreaks between attributes. Why do you expect
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}
instead of
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}

[~tripod] Under which circumstances should there be a linebreak in front of an 
attribute? \

Update: I see now, the logic is in 
https://github.com/apache/jackrabbit-filevault/blob/b83d2a605111ec50e4bbf46ed6e1cb1823846f7d/vault-core/src/main/java/org/apache/jackrabbit/vault/util/xml/serialize/XMLSerializer.java#L332
 and means, "if there is more than one attribute or namespace declaration 
prefix each attribute with a newline". Fixed in 
https://github.com/apache/jackrabbit-filevault/pull/68/commits/a5e73daf0d59c86aea26c31d83c6a0d80fa79bac


was (Author: kwin):
I made an attempt in https://github.com/apache/jackrabbit-filevault/pull/68. 
Some tests are still failing, but overall looks quite promising.
On question around linebreaks between attributes. Why do you expect
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}
instead of
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}

[~tripod] Under which circumstances should there be a linebreak in front of an 
attribute? 

> Remove copied classes of Xerces
> ---
>
> Key: JCRVLT-391
> URL: https://issues.apache.org/jira/browse/JCRVLT-391
> Project: Jackrabbit FileVault
>  Issue Type: Task
>  Components: vlt
>Affects Versions: 3.4.0
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: 3.4.2
>
>
> Currently the classes below {{o.a.j.v.util.xml}} seem to be a copy of Xerces 
> classes. Instead of just relying on an old copy one should use a proper Maven 
> dependency together with https://maven.apache.org/plugins/maven-shade-plugin/ 
> or https://bnd.bndtools.org/instructions/conditionalpackage.html to make sure 
> update to the latest version is possible.
> Also it needs to be clarified if the embedded Xerces should be listed 
> explicitly in 
> https://github.com/apache/jackrabbit-filevault/blob/trunk/LICENSE.txt.
> The original intent is stated in 
> https://github.com/apache/jackrabbit-filevault/blob/9fa6c72bf4bdf36331b50b9370f3ed826a4622e8/vault-core/src/main/java/org/apache/jackrabbit/vault/util/xml/serialize/XMLSerializer.java#L64.
> The only modifications to the original Xerces were linebreaks after 
> attributes and an alphabetic attribute sort order.
> The alternative is to use the {{javax.xml.transform}} API (JAXP 
> Transformation API). There is no official way though to control the order of 
> attribute, therefore I would recommend to already emit the attributes in the 
> correct order instead of reordering them with the output.  Controlling the 
> indentation of attributes is hard to achieve: 
> https://stackoverflow.com/questions/8393370/use-xslt-to-add-newlines-after-attributes



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (JCRVLT-391) Remove copied classes of Xerces

2019-11-29 Thread Konrad Windszus (Jira)


 [ 
https://issues.apache.org/jira/browse/JCRVLT-391?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Konrad Windszus reassigned JCRVLT-391:
--

Assignee: Konrad Windszus

> Remove copied classes of Xerces
> ---
>
> Key: JCRVLT-391
> URL: https://issues.apache.org/jira/browse/JCRVLT-391
> Project: Jackrabbit FileVault
>  Issue Type: Task
>  Components: vlt
>Affects Versions: 3.4.0
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: 3.4.2
>
>
> Currently the classes below {{o.a.j.v.util.xml}} seem to be a copy of Xerces 
> classes. Instead of just relying on an old copy one should use a proper Maven 
> dependency together with https://maven.apache.org/plugins/maven-shade-plugin/ 
> or https://bnd.bndtools.org/instructions/conditionalpackage.html to make sure 
> update to the latest version is possible.
> Also it needs to be clarified if the embedded Xerces should be listed 
> explicitly in 
> https://github.com/apache/jackrabbit-filevault/blob/trunk/LICENSE.txt.
> The original intent is stated in 
> https://github.com/apache/jackrabbit-filevault/blob/9fa6c72bf4bdf36331b50b9370f3ed826a4622e8/vault-core/src/main/java/org/apache/jackrabbit/vault/util/xml/serialize/XMLSerializer.java#L64.
> The only modifications to the original Xerces were linebreaks after 
> attributes and an alphabetic attribute sort order.
> The alternative is to use the {{javax.xml.transform}} API (JAXP 
> Transformation API). There is no official way though to control the order of 
> attribute, therefore I would recommend to already emit the attributes in the 
> correct order instead of reordering them with the output.  Controlling the 
> indentation of attributes is hard to achieve: 
> https://stackoverflow.com/questions/8393370/use-xslt-to-add-newlines-after-attributes



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (JCRVLT-391) Remove copied classes of Xerces

2019-11-29 Thread Konrad Windszus (Jira)


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

Konrad Windszus commented on JCRVLT-391:


I made an attempt in https://github.com/apache/jackrabbit-filevault/pull/68. 
Some test are failing.
On question around linebreaks between attributes. Why do you expect
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}
instead of
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}

[~tripod] Under which circumstances should there be a linebreak in front of an 
attribute? 

> Remove copied classes of Xerces
> ---
>
> Key: JCRVLT-391
> URL: https://issues.apache.org/jira/browse/JCRVLT-391
> Project: Jackrabbit FileVault
>  Issue Type: Task
>  Components: vlt
>Affects Versions: 3.4.0
>Reporter: Konrad Windszus
>Priority: Major
> Fix For: 3.4.2
>
>
> Currently the classes below {{o.a.j.v.util.xml}} seem to be a copy of Xerces 
> classes. Instead of just relying on an old copy one should use a proper Maven 
> dependency together with https://maven.apache.org/plugins/maven-shade-plugin/ 
> or https://bnd.bndtools.org/instructions/conditionalpackage.html to make sure 
> update to the latest version is possible.
> Also it needs to be clarified if the embedded Xerces should be listed 
> explicitly in 
> https://github.com/apache/jackrabbit-filevault/blob/trunk/LICENSE.txt.
> The original intent is stated in 
> https://github.com/apache/jackrabbit-filevault/blob/9fa6c72bf4bdf36331b50b9370f3ed826a4622e8/vault-core/src/main/java/org/apache/jackrabbit/vault/util/xml/serialize/XMLSerializer.java#L64.
> The only modifications to the original Xerces were linebreaks after 
> attributes and an alphabetic attribute sort order.
> The alternative is to use the {{javax.xml.transform}} API (JAXP 
> Transformation API). There is no official way though to control the order of 
> attribute, therefore I would recommend to already emit the attributes in the 
> correct order instead of reordering them with the output.  Controlling the 
> indentation of attributes is hard to achieve: 
> https://stackoverflow.com/questions/8393370/use-xslt-to-add-newlines-after-attributes



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (JCRVLT-391) Remove copied classes of Xerces

2019-11-29 Thread Konrad Windszus (Jira)


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

Konrad Windszus edited comment on JCRVLT-391 at 11/29/19 3:23 PM:
--

I made an attempt in https://github.com/apache/jackrabbit-filevault/pull/68. 
Some tests are still failing, but overall looks quite promising.
On question around linebreaks between attributes. Why do you expect
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}
instead of
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}

[~tripod] Under which circumstances should there be a linebreak in front of an 
attribute? 


was (Author: kwin):
I made an attempt in https://github.com/apache/jackrabbit-filevault/pull/68. 
Some test are failing.
On question around linebreaks between attributes. Why do you expect
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}
instead of
{code}

http://www.jcp.org/jcr/1.0"; 
xmlns:nt="http://www.jcp.org/jcr/nt/1.0";
jcr:primaryType="nt:unstructured">




{code}

[~tripod] Under which circumstances should there be a linebreak in front of an 
attribute? 

> Remove copied classes of Xerces
> ---
>
> Key: JCRVLT-391
> URL: https://issues.apache.org/jira/browse/JCRVLT-391
> Project: Jackrabbit FileVault
>  Issue Type: Task
>  Components: vlt
>Affects Versions: 3.4.0
>Reporter: Konrad Windszus
>Priority: Major
> Fix For: 3.4.2
>
>
> Currently the classes below {{o.a.j.v.util.xml}} seem to be a copy of Xerces 
> classes. Instead of just relying on an old copy one should use a proper Maven 
> dependency together with https://maven.apache.org/plugins/maven-shade-plugin/ 
> or https://bnd.bndtools.org/instructions/conditionalpackage.html to make sure 
> update to the latest version is possible.
> Also it needs to be clarified if the embedded Xerces should be listed 
> explicitly in 
> https://github.com/apache/jackrabbit-filevault/blob/trunk/LICENSE.txt.
> The original intent is stated in 
> https://github.com/apache/jackrabbit-filevault/blob/9fa6c72bf4bdf36331b50b9370f3ed826a4622e8/vault-core/src/main/java/org/apache/jackrabbit/vault/util/xml/serialize/XMLSerializer.java#L64.
> The only modifications to the original Xerces were linebreaks after 
> attributes and an alphabetic attribute sort order.
> The alternative is to use the {{javax.xml.transform}} API (JAXP 
> Transformation API). There is no official way though to control the order of 
> attribute, therefore I would recommend to already emit the attributes in the 
> correct order instead of reordering them with the output.  Controlling the 
> indentation of attributes is hard to achieve: 
> https://stackoverflow.com/questions/8393370/use-xslt-to-add-newlines-after-attributes



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (JCRVLT-347) Enable ignored principal-based ITs once Oak 1.18.0 is released

2019-11-29 Thread Angela Schreiber (Jira)


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

Angela Schreiber commented on JCRVLT-347:
-

[~kwin], patch looks good to me. as far as your question regarding oak 1.18 is 
concerned, i don't see any specific issue with that very oak version and the 
issue at hand. one thing that comes to my mind though is that moving 
jackrabbit-api to oak with a new artifact-id might impact running fvault with 
older aem versions. but that will not be limited to fvault... if it was indeed 
an issue, sling would also be impacted. but i might well be mistaken.

> Enable ignored principal-based ITs once Oak 1.18.0 is released
> --
>
> Key: JCRVLT-347
> URL: https://issues.apache.org/jira/browse/JCRVLT-347
> Project: Jackrabbit FileVault
>  Issue Type: Task
>  Components: vlt
>Reporter: Angela Schreiber
>Priority: Minor
> Fix For: 3.4.2
>
>
> the fix for JCRVLT-340 comes with 3 tests that are currently marked ignored 
> due to their dependency to a fix that will be available with Oak 1.18.0.  
> this issues serves as reminder to enable the affected test cases (all with 
> ImportMode.REPLACE)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)