You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Michael Ralston <mi...@ralston.id.au> on 2006/05/16 09:48:42 UTC
PublicationManager can't find 'lenya' publication
I've implemented my own EjbPublicationManager and changed the
PublicationManager in lenya.roles to my implementation.
When I request http://localhost:8080/lenya/default/authoring/index.html
I get the content I expect, but the CSS and images etc don't load.
My PublicationManager is telling me there are requests for a 'lenya'
publication. There doesn't seem to be anything special in the default
PublicationManager to deal with this request. How is it handled?
Michael
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: PublicationManager can't find 'lenya' publication
Posted by Michael Wechner <mi...@wyona.com>.
Michael Ralston wrote:
> On Tuesday 16 May 2006 17:48, Michael Ralston wrote:
>
>> I've implemented my own EjbPublicationManager and changed the
>> PublicationManager in lenya.roles to my implementation.
>>
>> When I request http://localhost:8080/lenya/default/authoring/index.html
>> I get the content I expect, but the CSS and images etc don't load.
>>
>> My PublicationManager is telling me there are requests for a 'lenya'
>> publication. There doesn't seem to be anything special in the default
>> PublicationManager to deal with this request. How is it handled?
>>
>>
>
> I ended up finding the cause of this. The default publication manager allows
> you to create a publication object which has no real association with a
> publication. Eg, you can create a publication named 'index.html' for the
> request http://localhost:8080/lenya/index.html.
>
> The publication object is then passed along a few objects and then checked if
> it is real by .exists()
>
> My publication manager simply threw an exception when it was not a valid
> publication and this exception propagated all the way out to cocoon.
>
> In short... I don't think it makes sense to be able to create publication
> objects for things that aren't publications.
>
sounds reasonable, whereas I am not sure if I fully understand to be honest.
Michi
> Michael
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
> For additional commands, e-mail: dev-help@lenya.apache.org
>
>
>
--
Michael Wechner
Wyona - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
michael.wechner@wyona.com michi@apache.org
+41 44 272 91 61
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: PublicationManager can't find 'lenya' publication
Posted by Andreas Hartmann <an...@apache.org>.
Michael Ralston wrote:
> On Wednesday 17 May 2006 17:17, Andreas Hartmann wrote:
>> Michael Ralston wrote:
>>> In short... I don't think it makes sense to be able to create publication
>>> objects for things that aren't publications.
>> Yes, I agree. But when I tried to change it I had the feeling that the
>> impact on the codebase is quite high, and the improvement is not worth
>> taking the risk.
>>
>
> I was forced to make the changes as this is how I had already coded my EJB
> objects to function. I found there was 11 different locations which had a
> Publication returned, and I checked these for the PublicationException.
We could apply these changes to the trunk - would you be interested
in filing an enhancement bug and attaching a patch? (if it is not
too complicated to isolate these changes)
>> BTW, the draft for the new repository API doesn't allow creating
>> objects for non-existing publication.
>>
>
> Where is the draft repository API, I would be interested in reading it and
> maybe contributing to it. As I am probably one of the only people that has
> reimplemented a large number of lenya interfaces (with a different backend
> focus), I may have a different perspective on things.
The API draft is located in the "repository" module, a JCR-based
implementation is located in the "jcr" module.
You can't really use it yet, but you can run the tests:
build.sh modules.test
-- Andreas
--
Andreas Hartmann
Wyona Inc. - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
andreas.hartmann@wyona.com andreas@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: PublicationManager can't find 'lenya' publication
Posted by Michael Ralston <mi...@ralston.id.au>.
On Wednesday 17 May 2006 17:17, Andreas Hartmann wrote:
> Michael Ralston wrote:
> > In short... I don't think it makes sense to be able to create publication
> > objects for things that aren't publications.
>
> Yes, I agree. But when I tried to change it I had the feeling that the
> impact on the codebase is quite high, and the improvement is not worth
> taking the risk.
>
I was forced to make the changes as this is how I had already coded my EJB
objects to function. I found there was 11 different locations which had a
Publication returned, and I checked these for the PublicationException.
> BTW, the draft for the new repository API doesn't allow creating
> objects for non-existing publication.
>
Where is the draft repository API, I would be interested in reading it and
maybe contributing to it. As I am probably one of the only people that has
reimplemented a large number of lenya interfaces (with a different backend
focus), I may have a different perspective on things.
Michael
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: PublicationManager can't find 'lenya' publication
Posted by Andreas Hartmann <an...@apache.org>.
Michael Ralston wrote:
[...]
> In short... I don't think it makes sense to be able to create publication
> objects for things that aren't publications.
Yes, I agree. But when I tried to change it I had the feeling that the
impact on the codebase is quite high, and the improvement is not worth
taking the risk.
BTW, the draft for the new repository API doesn't allow creating
objects for non-existing publication.
-- Andreas
--
Andreas Hartmann
Wyona Inc. - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
andreas.hartmann@wyona.com andreas@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: PublicationManager can't find 'lenya' publication
Posted by Michael Ralston <mi...@ralston.id.au>.
On Tuesday 16 May 2006 17:48, Michael Ralston wrote:
> I've implemented my own EjbPublicationManager and changed the
> PublicationManager in lenya.roles to my implementation.
>
> When I request http://localhost:8080/lenya/default/authoring/index.html
> I get the content I expect, but the CSS and images etc don't load.
>
> My PublicationManager is telling me there are requests for a 'lenya'
> publication. There doesn't seem to be anything special in the default
> PublicationManager to deal with this request. How is it handled?
>
I ended up finding the cause of this. The default publication manager allows
you to create a publication object which has no real association with a
publication. Eg, you can create a publication named 'index.html' for the
request http://localhost:8080/lenya/index.html.
The publication object is then passed along a few objects and then checked if
it is real by .exists()
My publication manager simply threw an exception when it was not a valid
publication and this exception propagated all the way out to cocoon.
In short... I don't think it makes sense to be able to create publication
objects for things that aren't publications.
Michael
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org