cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Torsten Knodt <torstenkn...@datas-world.de>
Subject Re: cocoon:// design bug?
Date Sat, 17 May 2003 17:20:26 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> I did some spec-reading [1], and although the most general URI syntax
> doesn't specify the format of what follows the scheme (cocoon:),
> resolving relative URI's is only supported for those that use the
> hierarchical path syntax.
Yes. And thats what cocoon should be. It should work like file:.

> So in short, there's no problem as long as we assume we'll never have to
> resolve relative URL's against cocoon: base URL's. But I'd rather avoid
> posing this restriction.
> [1] http://www.ietf.org/rfc/rfc2396.txt
Bad. Very Bad. Assume you do <map:part src="cocoon:/blablalbla">. Now I want 
to resolve the URI's in this document against the given URI and then 
relativize against the URI of my current pipeline.

> I think we'd have a hard time convincing everyone here to change this
> syntax now. And it would break backwards compatibility with Cocoon 2.0.
I would suggest to introduce a new scheme, which also reflects better what it 
is, like sitemap:

> A possible solution would be to add relative URL resolving to the Source
> interface, so that the Cocoon source can use its own logic for this,
> while the URLSource can use e.g. the java.net.URL class.
This would also be a solution. Perhaps we could do both. Introduce sitemap:, 
to make the URI more standard. And add relativize and resolve to Source for 
the actual handling. This way also fragment identifiers could be handled.

> > My ideas so far:
> > The problem is, that you can't give a protocol and a relative URI. My
> > idea would be to help to get an absolute URI. We use an input module,
> > which gives back a prefix to the actual pipeline. The cocoon protocol
> > will be handled like the file protocol. So you can either give an
> > absolute URI, or use a relative uri, by prepending the prefix to the
> > current pipeline.
> > What do you think?
> I'm not following you here, maybe explaining with an example will help.
OK, problem would be I have a relative URI to my actual cocoon:... document. 
An idea to get it absolute would be to have the document's absolute URI 
accessible as input module. Then you can append the relative URI to the input 
module's output and get an absolute one.
But the idea you provided to modify Source seems much better to me. I think I 
will provide a patch for this. I already prepared a better AugmentTransformer 
which allows to resolve, relativize and mount URI's based on the 
ExtendedXLinkPipeline.

Regards
	Torsten
- -- 
Domain in provider transition, hope for smoothness. Planed date is 24.7.2003
pub 1024D/4CD29A2C 2001-01-12 Torsten Knodt <torstenknodt@datas-world.de>
 Schl.-Fingerabdruck = A2B1 C626 F819 7C58 B2F9 4F4C BF16 64B6 4CD2 9A2C
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE+xnCQvxZktkzSmiwRArMxAJ4iuXfgpw5TRYh0lj9UI90R9yrIGQCfYPFX
sD9G+KwBOT07nd5305hY+u8=
=CEw7
-----END PGP SIGNATURE-----


Mime
View raw message