[MGNLDAM-408] JcrAssetProvider should handle/provide paths relative to its rootPath Created: 03/Mar/14  Updated: 20/Mar/14  Resolved: 12/Mar/14

Status: Closed
Project: Magnolia DAM Module
Component/s: DAM JCR Provider
Affects Version/s: 2.0
Fix Version/s: 2.0

Type: Bug Priority: Neutral
Reporter: Magnolia International Assignee: Eric Hechinger
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
dependency
depends upon MGNLDAM-412 JcrAsset, JcrFolder, AbstractJcrItem ... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Epic Link: DAM / CMIS
Sprint: 5.3 Sprint 3, 5.3 Sprint 4

 Description   

To be verified with unit tests:

  • items returned by JcrAssetProvider should return a path that's relative to its rootPath (i.e if rootPath==/foo, then Asset.getPath()==/bar for an asset physically stored in /foo/bar in jcr.
  • get*ByPath should take paths relative to the rootPath (PathAwareAssetProvider.getAsset(/bar) should return the asset physically stored in /foo/bar in jcr.
  • Ideally, the provider should be isolated, such that a call to getAsset(someId) would fail if it points to an asset stored outside /foo.


 Comments   
Comment by Daniel Lipp [ 10/Mar/14 ]

Adaptions to JcrAssetProvider#createFolder and #createAsset require adapting the exception message as well. Right now the exception message would be very misleading in case that the passed node is not child of root.

Comment by Eric Hechinger [ 12/Mar/14 ]

This was corrected with the following commit c05d80bbad5cf367a739ea81ec2f9921f32b7228 done for MGNLDAM-415

Generated at Mon Feb 12 04:59:32 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.