On 5/31/07, Andreas Hartmann <[EMAIL PROTECTED]> wrote:
Richard Frovarp schrieb:
> Is there a way to call a page via it's UUID from a browser? My issue is
> that we translate from UUIDs to URLs when a page is being edited.

That's a very good point.

> If an
> object being targeted (image or link) changes path while the page is
> being edited, it then becomes lost. Links really don't matter if they
> are left as lenya-document as they aren't rendered. However, images need
> to be rendered. If there is some way of accessing a document via HTTP
> using it's UUID, a pre-processing instruction can be put in to handle
> creating those URLs, and things will be good.

We should certainly introduce such a URL space. It will also be helpful
for debugging. Should we use a particular prefix, or does the UUID space
itself provide enough safety from name clashes?

  /{pubId}/{area}/{uuid}.png

In theory, this would be sufficient:

- It is very unlikely to have a URL with this syntax which is
  not a UUID.

- If the "natural" URL space uses UUIDs, there is no risk for clashes
  because UUIDs are unique.

The problem is that we'd need to check if a document with this
UUID exists for each call which matches

  /{pubId}/{area}/????????-????-????-????-????????????

to avoid masking the "natural" URL space of the publication.
Considering this, it might make sense to use a particular prefix, e.g.:

  /{pubId}/{area}/lenya-uuid/{uuid}.png

WDYT?

-- Andreas


--
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch

I think using a prefix should result in simpler xmaps and with reduced
dependencies on the particular UUID implementation.  (I don't like the
idea of matching on a ????????-????-????-????-???????????? pattern, it
seems hacky somehow.)

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to