You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Ted Steen <te...@gmail.com> on 2005/09/20 14:14:01 UTC
hivemind problem missing service constructor
i got this hivemodule
<service-point
id="hibernateSession"
interface="org.hibernate.Session"/>
<service-point
id="hibernateSessionFactory"
interface="org.apache.hivemind.ServiceImplementationFactory"/>
<implementation service-id="hibernateSessionFactory">
<invoke-factory>
<construct
class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
initialize-method="init"/>
</invoke-factory>
</implementation>
and yet I get this error:
Error: No module has contributed a service constructor for service
point se.liu.studorg.blaskan.web.hibernateSession.
the constructing service point is the hibernateSessionFactory.
I'm very new on hibernate
--
/ted
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: hivemind problem missing service constructor
Posted by Ted Steen <te...@gmail.com>.
I really can't figure out what is wrong here.. :(
I did some debugging and found out that the hibernateSession is
actually created, and the method setSession(...) in "BlaskanManager"
is invoked. So somewhere is there a session created but still I get
"Unable to construct service
se.liu.studorg.blaskan.web.hibernateSession"
On 9/20/05, Ted Steen <te...@gmail.com> wrote:
> ok, some more trouble with hivemind..
> this is in my hivemind.xml
>
> <service-point
> id="hibernateSession"
> interface="org.hibernate.Session"/>
>
> <service-point
> id="hibernateSessionFactory"
> interface="org.apache.hivemind.ServiceImplementationFactory"/>
>
> <service-point
> id="blaskanManager"
> interface="se.liu.studorg.blaskan.web.BlaskanManager" />
>
>
>
> <implementation service-id="hibernateSession">
> <invoke-factory
> service-id="hibernateSessionFactory"
> model="threaded"/>
> </implementation>
>
> <implementation service-id="hibernateSessionFactory">
> <invoke-factory>
> <construct
> class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
> initialize-method="init"/>
> </invoke-factory>
> </implementation>
>
> <implementation service-id="blaskanManager">
> <invoke-factory>
> <construct class="se.liu.studorg.blaskan.web.BlaskanManager" />
> </invoke-factory>
> </implementation>
>
> now when I try to use this injected object:
> @InjectObject("service:se.liu.studorg.blaskan.web.blaskanManager")
>
> I get
> Unable to construct service
> se.liu.studorg.blaskan.web.hibernateSession: Error at
> context:/WEB-INF/hivemodule.xml, line 24, column 26: Parameters to
> service implementation factory hibernateSessionFactory contains no
> contributions but expects exactly one contribution.
>
> 21 <implementation service-id="hibernateSession">
> 22 <invoke-factory
> 23 service-id="hibernateSessionFactory"
> 24 model="threaded"/>
> 25 </implementation>
>
>
> thanks!
>
> On 9/20/05, Kent Tong <ke...@cpttm.org.mo> wrote:
> > Ted Steen <ted.steen <at> gmail.com> writes:
> >
> > >
> > > i got this hivemodule
> > > <service-point
> > > id="hibernateSession"
> > > interface="org.hibernate.Session"/>
> > >
> > > <service-point
> > > id="hibernateSessionFactory"
> > > interface="org.apache.hivemind.ServiceImplementationFactory"/>
> > >
> > > <implementation service-id="hibernateSessionFactory">
> > > <invoke-factory>
> > > <construct
> > > class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
> > > initialize-method="init"/>
> > > </invoke-factory>
> > > </implementation>
> > >
> > > and yet I get this error:
> > > Error: No module has contributed a service constructor for service
> > > point se.liu.studorg.blaskan.web.hibernateSession.
> >
> > It's saying there is no implementation for hibernateSession. Maybe
> > you'd like something like:
> >
> > <service-point
> > id="hibernateSession"
> > interface="org.hibernate.Session">
> > <invoke-factory service-id="hibernateSessionFactory"/>
> > </service-point>
> >
> > --
> > Author of an e-Book for learning Tapestry (http://www.agileskills2.org/EWDT)
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> >
> >
>
>
> --
> /ted
>
--
/ted
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: hivemind problem missing service constructor
Posted by Kent Tong <ke...@cpttm.org.mo>.
Ted Steen <ted.steen <at> gmail.com> writes:
>
> <service-point
> id="hibernateSessionFactory"
interface="org.apache.hivemind.ServiceImplementationFactory"/>
> I get
> Unable to construct service
> se.liu.studorg.blaskan.web.hibernateSession: Error at
> context:/WEB-INF/hivemodule.xml, line 24, column 26: Parameters to
> service implementation factory hibernateSessionFactory contains no
> contributions but expects exactly one contribution.
Try:
<service-point
id="hibernateSessionFactory"
interface="org.apache.hivemind.ServiceImplementationFactory"
parameters-occurs="none"/>
--
Author of a book for learning Tapestry (www.agileskills2.org/EWDT)
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: hivemind problem missing service constructor
Posted by Ted Steen <te...@gmail.com>.
ok, some more trouble with hivemind..
this is in my hivemind.xml
<service-point
id="hibernateSession"
interface="org.hibernate.Session"/>
<service-point
id="hibernateSessionFactory"
interface="org.apache.hivemind.ServiceImplementationFactory"/>
<service-point
id="blaskanManager"
interface="se.liu.studorg.blaskan.web.BlaskanManager" />
<implementation service-id="hibernateSession">
<invoke-factory
service-id="hibernateSessionFactory"
model="threaded"/>
</implementation>
<implementation service-id="hibernateSessionFactory">
<invoke-factory>
<construct
class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
initialize-method="init"/>
</invoke-factory>
</implementation>
<implementation service-id="blaskanManager">
<invoke-factory>
<construct class="se.liu.studorg.blaskan.web.BlaskanManager" />
</invoke-factory>
</implementation>
now when I try to use this injected object:
@InjectObject("service:se.liu.studorg.blaskan.web.blaskanManager")
I get
Unable to construct service
se.liu.studorg.blaskan.web.hibernateSession: Error at
context:/WEB-INF/hivemodule.xml, line 24, column 26: Parameters to
service implementation factory hibernateSessionFactory contains no
contributions but expects exactly one contribution.
21 <implementation service-id="hibernateSession">
22 <invoke-factory
23 service-id="hibernateSessionFactory"
24 model="threaded"/>
25 </implementation>
thanks!
On 9/20/05, Kent Tong <ke...@cpttm.org.mo> wrote:
> Ted Steen <ted.steen <at> gmail.com> writes:
>
> >
> > i got this hivemodule
> > <service-point
> > id="hibernateSession"
> > interface="org.hibernate.Session"/>
> >
> > <service-point
> > id="hibernateSessionFactory"
> > interface="org.apache.hivemind.ServiceImplementationFactory"/>
> >
> > <implementation service-id="hibernateSessionFactory">
> > <invoke-factory>
> > <construct
> > class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
> > initialize-method="init"/>
> > </invoke-factory>
> > </implementation>
> >
> > and yet I get this error:
> > Error: No module has contributed a service constructor for service
> > point se.liu.studorg.blaskan.web.hibernateSession.
>
> It's saying there is no implementation for hibernateSession. Maybe
> you'd like something like:
>
> <service-point
> id="hibernateSession"
> interface="org.hibernate.Session">
> <invoke-factory service-id="hibernateSessionFactory"/>
> </service-point>
>
> --
> Author of an e-Book for learning Tapestry (http://www.agileskills2.org/EWDT)
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
--
/ted
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: hivemind problem missing service constructor
Posted by Kent Tong <ke...@cpttm.org.mo>.
Ted Steen <ted.steen <at> gmail.com> writes:
>
> i got this hivemodule
> <service-point
> id="hibernateSession"
> interface="org.hibernate.Session"/>
>
> <service-point
> id="hibernateSessionFactory"
> interface="org.apache.hivemind.ServiceImplementationFactory"/>
>
> <implementation service-id="hibernateSessionFactory">
> <invoke-factory>
> <construct
> class="se.liu.studorg.blaskan.web.HibernateSessionFactory"
> initialize-method="init"/>
> </invoke-factory>
> </implementation>
>
> and yet I get this error:
> Error: No module has contributed a service constructor for service
> point se.liu.studorg.blaskan.web.hibernateSession.
It's saying there is no implementation for hibernateSession. Maybe
you'd like something like:
<service-point
id="hibernateSession"
interface="org.hibernate.Session">
<invoke-factory service-id="hibernateSessionFactory"/>
</service-point>
--
Author of an e-Book for learning Tapestry (http://www.agileskills2.org/EWDT)
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org