Jeff,
>
> Yes, I see your point. There are a few components ('html', 'xml',
> 'xslt') which ought to have one, common definition. So in general we
> should follow your suggested rule of putting components in sitemap.xmap
> if they are shared across multiple subsitemaps.
>
Good, I happy that you understant what I mean.
>
>
> Yes, but that is always true. I am talking about the commonest scenario,
> where I don't use the new Wiki format and haven't overridden
> forrest.xmap. I don't care about new formats; I just want my existing
> site to work. Now it doesn't work _at all_ (not just one unsupported
> format), because the new forrest.xmap relies on a component that my
> sitemap.xmap doesn't provide. For example:
>
> X [0] index.html BROKEN: Type 'config' is not defined for 'select'
> at
> file:/home/jeff/src/jira-docs-cvs/web/build/tmp/context/menu.xmap:38:35
>
>
You are asuming that everyone overwrites sitemap. Now we have a problem
here, we are using sitemap that belows to forrest to customize, we need
to find a fix on this. A way that you can customized without touching
something that belongs to forrest.
For users that have sitemap, if they overwrite then it will not work,
navigation.xmap, static.xmap have changed names so they have to modify
the latest sitemap version anyway.
>>So to avoid this you want to had the same definition more than once?
>
>
> Yes, if necessary. Which is better: to duplicate a definition, or have
> everyone's site break whenever we change a subsitemap? What is the cost
> of a duplicated definition? In the worst case, a change to sitemap.xmap
> has no effect. The alternative is to _guarantee_ things breaking.
>
I would like to see things tidier, if having the definition on sitemap
is a problem then lets move it to the submaps, then things will break as
well for anyone that has overwrite the submaps.
So we need a decision:
Let the sitemap be overwrite by the user so it only defines the URI
space (pipelines) and call the submaps.
>
>>I looked on the issue with the menu.xmap and I think that the config
>>component can be used in more than one map, so it makes sense to have
>>it on sitemap.
>
>
> Yes, it _can_ be used in multiple places, but currently it is used in
> only one. Things should be scoped locally until the necessity for global
> scoping becomes apparent.
>
>
After the definition is in place, when you overwrite sitemap, the scope
is all the submaps.
Keep components definitions local/globalize
>>I rather have an error when I upgrade than a side effect that I am not
>>aware of.
>
>
> As a user, I'd rather have my site _not_ be broken every time someone
> adds a new feature to Forrest ;)
>
>
I do not mind if the definition is on sitemap or in the submaps, what I
really care is that thinks are tidier. At the moment they are not, and
it makes harder to find problems.
Cheers,
Cheche
|