Justin Deoliveira ha scritto:
Well currently templates can exist in a couple of places:
1. Inside a particular featureType or coverage config directory
2. Under "templates/<namespace>" for namespace wide templates
3. An arbitrary path under feature types or coverages
I am not sure if 3 is of much use. I seem to remember being able to store templates directly under "templates", for defaults. BUt looking at the lookup scheme it does not seem so.
Regardless,I would see these being translated to:
1. Same
2. Under workspaces/<ws>
3. Not sure if we need this one
We could also add a lookup directly under templates for server wide defaults.
Thoughts?
http://jira.codehaus.org/browse/GEOS-3055
is proof that at least someone is using global templates. And in
fact, our template documentation says you can put them into
the featureTypes directory to affect all types:
http://geoserver.org/display/GEOSDOC/GetFeatureInfo+templates
So I would say that yes, we need that for backwards compatibility.
I personally don't find odd that people might want a different default
template, independent of the namespace/workspace.
For 3, what about putting the templates directly under
workspaces instead of making up a separate directory?
It follows the general idea of the other .ftl:
workspaces/<ws>/<store>/<typeName>/content.ftl (type specific)
workspaces/<ws>/content.ftl (workspace specific)
workspaces/content.ftl (totally generic)
(and this makes me wonder about
workspaces/<ws>/<store>/content.ftl (store specific)
too)
Another thing that makes me wonder is the resource/publishing
split. In the future I guess we'll want map and layer specific
templates, and use the resource ones only as fallbacks?
Cheers
Andrea
Cheers
Andrea
Andrea Aime wrote:
Justin Deoliveira ha scritto:
So in the new system the specific .ftl files would be located under:
workpaces/<ws>/<ds>/<ft>/*.ftl
Makes sense. Where are the global templates going to be located?
In the root?
And yes, on the data directory import phase, all the templates and any other files in the original feature type directory is copied over.
As for lookups, they will still be looking at the old directory structure, so that will need to be changes. Will open a jira for this.
Cool
Cheers
Andrea
--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.