You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Harald Entner <Ha...@workflow.at> on 2008/09/24 16:49:51 UTC
Problem with Springs AnnotationSessionFactoryBean
Hello,
i'm facing a problem when using cocoon 2.2, the rcl plugin and
AnnotationSessionFactoryBean. (spring)
we have the following infrastructure (simple view):
-> core
-> a list of seperate projects. (blocks)
The tables that belong to annotated classes placed in the core are
generated when running the core itself, but are not generated for
annotated classes placed in one of the seperate projects. (The problem
only occurs when one of these blocks starts up seperately (using the rcl
plugin).
We have only one Servlet-service, so
# at.workflow.webdesk.webdesk-core.service%classes-dir=./target/classes
in the rcl.properties is outcommented. (obviously not for the core). So we
had to add the target/classes directory to the classpath of the
run:jetty:run plugin.
Jetty itself starts up fine and after adding the classes directory of the
target dir to the classpath of the run-jetty-run plugin, the classes (of
the seperate project) are found and passed to the
AnnotationSessionFactoryBean. (but the tables are not generated - which is
strange somehow)
When the jar is deployed to a webserver everything works fine again, but
the possibility to run a block on its own is a great benefit that we don't
want to miss.
Has anybody experience in this area? Or had eventually the same problem?
regards,
Harald
Re: Problem with Springs AnnotationSessionFactoryBean
Posted by Harald Entner <Ha...@workflow.at>.
Hello,
i answer myself, eventually someone will search the list for a similar
problem. I didn't found a solution to start a block seperately and include
annotations when no Servlet-Service is defined. Although, it's possible
to define a webapp, that includes the necessary artifacts. (similar to the
webapp in the cocoon distribution) and then startup within the src or
target directory. Then everything works fine again.
It's definitely a problem of the rcl-plugin, so the subject of the mail
was not choosen wisely.
cheers,
harald
<Ha...@workflow.at> wrote on 24.09.2008 16:49:51:
>
> Hello,
>
> i'm facing a problem when using cocoon 2.2, the rcl plugin and
> AnnotationSessionFactoryBean. (spring)
>
> we have the following infrastructure (simple view):
>
> -> core
> -> a list of seperate projects. (blocks)
>
> The tables that belong to annotated classes placed in the core are
> generated when running the core itself, but are not generated for
> annotated classes placed in one of the seperate projects. (The
> problem only occurs when one of these blocks starts up seperately
> (using the rcl plugin).
>
> We have only one Servlet-service, so
>
> # at.workflow.webdesk.webdesk-core.service%classes-dir=./target/classes
>
> in the rcl.properties is outcommented. (obviously not for the core).
> So we had to add the target/classes directory to the classpath of
> the run:jetty:run plugin.
>
> Jetty itself starts up fine and after adding the classes directory
> of the target dir to the classpath of the run-jetty-run plugin, the
> classes (of the seperate project) are found and passed to the
> AnnotationSessionFactoryBean. (but the tables are not generated -
> which is strange somehow)
>
> When the jar is deployed to a webserver everything works fine again,
> but the possibility to run a block on its own is a great benefit
> that we don't want to miss.
>
> Has anybody experience in this area? Or had eventually the same problem?
>
> regards,
>
> Harald