[Building Sakai] Portal NEO Prefix

David Adams da1 at vt.edu
Sat Mar 16 07:32:03 PDT 2013


Charles Severance wrote:
> Just schlepping the neo stuff back to the non-prefixed file names is a
> poor solution so lazy tools that are out of spec don't have to fix
> themselves is a mistake and adds more technical debt.

I don't think that's the problem. The problem is that tools and humans
both are reasonably expecting that the value of "skin.default" is
actually the skin the portal will offer up. The fix provided for
STAT-345[1] is to just duplicate the logic from portal for building
the portal name. Namely: fetching the skin.default, portal.templates,
and portal.neoprefix properties, testing if portal.templates is
"neoskin" and skin.default doesn't start with portal.neoprefix, and
if so prepending portal.neoprefix to portal.skin.

[1] https://jira.sakaiproject.org/secure/attachment/35410/STAT-345.patch

That's an ugly hack even if it were in just one place in the code, but
cloning it to other tools would be a far, far worse solution. Kind of
like when every tool re-implemented the process for building a
self-referential URL, only in multiple variations on three primary
different methods?

> Because the names never changed for such a long time - folks could do
> something quick and dirty but wrong in tools - lets not reward the
> behavior.  Lets catch and fix the tools.

Sure, fix any tools that are doing it wrong (a quick grep of our 2.9.1
code reveals eight tools as well as kernel all pull the "skin.default"
property, none of them except login checks the portal.neoprefix or
portal.templates properties as well).

Regardless of where the problem lies, code-wise, the current setup is
confusing to humans and needs to be changed.

-dave


More information about the sakai-dev mailing list