Hi Devs,
At
http://design.xwiki.org/xwiki/bin/view/Proposal/NestedSpaces#HDatabaseModel I have
started drafting some naive impl for Nested Spaces. I believe Edy has provided some other
links with probably more elaborate algorithms that we should study (such
as
http://www.slideshare.net/billkarwin/models-for-hierarchical-data).
In any case I’ve also started a Problem section
at
http://design.xwiki.org/xwiki/bin/view/Proposal/NestedSpaces#HProblems where I’ve
listed one item FTM. I’m pasting it here:
“
* For ex if you do HQL (or you use an extension that does) like {{code}}where doc.space =
'somespace'{{/code}} and add a parent or child Space for ##somespace## then the
query will not return anything anymore since you can have something like
##parent.somespace.child## in the DB in the ##space## column (since we store the full
space reference in there for NS).
** Solution 1: Rewrite the queries to use something like {{code}}where doc.space =
'somespace' or doc.space like '%.somespace'{{/code}}.
** Solution 2: Don't modify the ##space## column and add a ##spaceReference## one.
This is not perfect in case there are several spaces named ##somespace##
** Solution 3: ??
“
I’d be curious to know what you think about it and if you have ideas.
Feel free to list other problems you can see there and your ideas for solving them.
Thanks
-Vincent