Jakub Gorgolewski created JCRVLT-363:
----------------------------------------
Summary: .content.xml of ancestor nodes not included in package
Key: JCRVLT-363
URL: https://issues.apache.org/jira/browse/JCRVLT-363
Project: Jackrabbit FileVault
Issue Type: Bug
Components: package maven plugin
Affects Versions: package-maven-plugin-1.0.4
Reporter: Jakub Gorgolewski
Attachments: ancestor-bug-example.zip,
ancestor-package-test-pkg-1.0.0-SNAPSHOT.zip
Packaging does not include ancestor node .content.xml files, for example if
project has following files:
{noformat}
jcr_root/apps/wcm/core/resources
jcr_root/apps/wcm/core/resources/.content.xml
jcr_root/apps/wcm/core/resources/languages
jcr_root/apps/wcm/core/resources/languages/.content.xml
jcr_root/apps/wcm/core/resources/languages/_rep_policy.xml{noformat}
And filter is set to:
{code:java}
<filter root="/apps/wcm/core/resources/languages" />
{code}
Then .content.xml for resources directory is still excluded with following
warning:
{noformat}
[WARNING] File /.../jcr_root/apps/wcm/core/resources/.content.xml not covered
by a filter rule and therefore not contained in the resulting package
{noformat}
This is required especially in case of /apps overloads where specific ancestor
folders require specific primary type for package to successfully install (and
those folders may or may not exist on target environment).
Potential workaround for this issue is to use filters in following form:
{code:java}
<filter root="/apps/wcm/core/resources">
<exclude pattern="/apps/wcm/core/resources(/.*)?" />
<include pattern="/apps/wcm/core/resources/languages" />
</filter>{code}
I'm attaching example project and resulting package.
On related note, it seemed to have veen covered by test cases but recent commit
removed .conent.xml files from expected list:
[https://github.com/apache/jackrabbit-filevault-package-maven-plugin/commit/2d4a4490ebd0ffad3800789e839a5b322b9bab71#diff-48d0ab4fe7c714f2424acbe6b6ad7f2b]
FYI [~kwin]
--
This message was sent by Atlassian Jira
(v8.3.2#803003)