Skip to content
This repository was archived by the owner on Jan 3, 2019. It is now read-only.

Persist jcr/xml in hierarchy structure.#49

Open
lsitu wants to merge 1 commit intofcrepo4-archive:masterfrom
lsitu:feature/jcrxml-tree
Open

Persist jcr/xml in hierarchy structure.#49
lsitu wants to merge 1 commit intofcrepo4-archive:masterfrom
lsitu:feature/jcrxml-tree

Conversation

@lsitu
Copy link
Contributor

@lsitu lsitu commented Aug 8, 2014

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These parameters are too complicated and redundant: baseURL and baseURL + id

@awoods
Copy link

awoods commented Aug 11, 2014

This implementation creates the following directories:
fcrepo4-jcrxml/
└── http:
└── localhost:8080
└── rest
└── collection
└── book
└── page
└── page-jcr.xml

The directory should start at "collection"

@awoods awoods closed this Aug 11, 2014
@awoods awoods reopened this Aug 11, 2014
@lsitu
Copy link
Contributor Author

lsitu commented Aug 12, 2014

Okay, I've rebase and squash it into one commit lsitu@4274f9f. The compiling error/conflicts should be fixed now.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"parent" should actually be "parentID", no?
When the index() call concatenates "baseURL" and "parent" it should have a valid URI.

Should this instead be:
final String parentID = uri.substring(uri.lastIndexOf("/"));

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@awoods It sounds good to me. The term "parent" was used that way in the source codes. Would you like me to make the change now?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lsitu, it is not just the name of the variable, but the logic in creating the substring that likely needs to change.
I believe the current logic is incorrect.

@lsitu
Copy link
Contributor Author

lsitu commented Aug 13, 2014

I've updated it to use the parentID and made the change to use reindexURI( child, "", true ) instead of splitting the child url into two parts like baseURL+id.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants