You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Jason McKerr <ja...@osuosl.org> on 2005/06/24 01:31:52 UTC

Installment 2, Spring

I've finished the second (more simple) installment of Spring with OJB if 
anyone is interested.

http://staff.osuosl.org/~mckerrj/?p=4

Jason

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Jason McKerr <ja...@osuosl.org>.
Hey Alexandre,

I agree with you greatly.  I do think that we're starting to see a lot 
of Spring usage, and I like it for many of the same reasons Thomas 
mentioned (Thomas, installment two has the DAO stuff you talk about 
added back in).

As an FYI, take a look at the Kuali project (http://www.kuali.org/).  It 
is a massive undertaking being developed by a group universities, 
private companies, and groups like the Open Source Lab that will result 
in an ERP system including Financial Information System, Research 
Administration and all that sort of thing.  The primary toolset is 
OJB/Spring with struts on the front. 

So I think these types of tools are gaining traction.

Jason

Alexandre Borgoltz wrote:

> Jason,
>
> I have not read your articles for the moment but IMHO this is a very 
> positive initiative.
> I like to work with OJB, and I also appreciate Spring a lot - they are 
> both great tools.
> Spring aims at integration of various frameworks. It has a strong 
> persistence layer integration - integration is great with Hibernate, 
> JDO, iBatis. But you will never find any reference to OJB.
> I suppose the reasons are mainly political but anyway, it's a 
> shame.For example, Spring is a great factor of expansion for 
> Hibernate, as every little sample it provides uses hibernate.
> It would be a shame if OJB did not take the opportunity.
>
> I am not yet a Spring expert, but tell me if I can help in anyway!
>
> I'd also be interested in reading what you OJB committers (Armin, 
> Thomas, Jacob, Martin...) think about it!
>
> Alexandre BORGOLTZ
> Head of Technology
>
> SmartJog SA
> Phone: +33 (0)1 4996 6324
> Fax: +33 (0)1 4996 6405
> Mobile: +33 (0)6 8882 1417
> alexandre.borgoltz@smartjog.com
>
>
> Jason McKerr wrote:
>
> > I've finished the second (more simple) installment of Spring with 
> OJB if anyone is interested.
> >
> > http://staff.osuosl.org/~mckerrj/?p=4
> >
> > Jason
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Armin Waibel <ar...@apache.org>.
Hi,

Alexandre Borgoltz wrote:
> Jason,
> 
> I have not read your articles for the moment but IMHO this is a very 
> positive initiative.
> I like to work with OJB, and I also appreciate Spring a lot - they are 
> both great tools.
> Spring aims at integration of various frameworks. It has a strong 
> persistence layer integration - integration is great with Hibernate, 
> JDO, iBatis. But you will never find any reference to OJB.
> I suppose the reasons are mainly political but anyway, it's a shame.

I don't think that the reasons are "political" (the contact with Juergen 
Hoeller from Spring come along well).
JDO, Hibernate, iBatis are (currently ;-)) more popular than OJB, thus 
in the first instance you will find references about these frameworks.
For OJB-1.1 we intend (among other things) to make the Spring 
integration easier. OJB-1.1 will be a big step forward.


> For 
> example, Spring is a great factor of expansion for Hibernate, as every 
> little sample it provides uses hibernate.

The winner takes it all ;-)

regards,
Armin


> It would be a shame if OJB did not take the opportunity.
> 
> I am not yet a Spring expert, but tell me if I can help in anyway!
> 
> I'd also be interested in reading what you OJB committers (Armin, 
> Thomas, Jacob, Martin...) think about it!
>




> Alexandre BORGOLTZ
> Head of Technology
> 
> SmartJog SA
> Phone: +33 (0)1 4996 6324
> Fax: +33 (0)1 4996 6405
> Mobile: +33 (0)6 8882 1417
> alexandre.borgoltz@smartjog.com
> 
> 
> Jason McKerr wrote:
> 
>  > I've finished the second (more simple) installment of Spring with OJB 
> if anyone is interested.
>  >
>  > http://staff.osuosl.org/~mckerrj/?p=4
>  >
>  > Jason
>  >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Alexandre Borgoltz <al...@smartjog.com>.
 Jason,

I have not read your articles for the moment but IMHO this is a very 
positive initiative.
I like to work with OJB, and I also appreciate Spring a lot - they are 
both great tools.
Spring aims at integration of various frameworks. It has a strong 
persistence layer integration - integration is great with Hibernate, 
JDO, iBatis. But you will never find any reference to OJB.
I suppose the reasons are mainly political but anyway, it's a shame.For 
example, Spring is a great factor of expansion for Hibernate, as every 
little sample it provides uses hibernate.
It would be a shame if OJB did not take the opportunity.

I am not yet a Spring expert, but tell me if I can help in anyway!

I'd also be interested in reading what you OJB committers (Armin, 
Thomas, Jacob, Martin...) think about it!

Alexandre BORGOLTZ
Head of Technology

SmartJog SA
Phone: +33 (0)1 4996 6324
Fax: +33 (0)1 4996 6405
Mobile: +33 (0)6 8882 1417
alexandre.borgoltz@smartjog.com


Jason McKerr wrote:

 > I've finished the second (more simple) installment of Spring with OJB 
if anyone is interested.
 >
 > http://staff.osuosl.org/~mckerrj/?p=4
 >
 > Jason
 >

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 3, Spring, Text file for Armin

Posted by Armin Waibel <ar...@apache.org>.
Hi Jason,

thanks for clarification. So I think it will be the best to remove 
Robert's howto in 1.x trunk and replace it with your up-to-date howto 
(till OJB1.1 is released and Spring is upgraded to 1.1).

regards,
Armin

Jason McKerr wrote:
> Hi Armin,
> 
> I read through the one that Robert did.  He actually helped me quite a 
> bit with the three that I wrote.  There are a couple of important things 
> there.
> 
> First, Robert's only covers configuration files.  Land while it does 
> that well (and Robert helped me quite a bit with my config setup) it 
> only covers the basics.  The three articles that I wrote covers 
> configuration, interception patterns with DAO, OJB implementations, 
> advanced DAO pattersn.  Also Robert's only covers local datasourcing 
> using Springs local datasource and the localOJBConfigurer.  The problem 
> with this is that it doesn't allow you to use server based/JNDI lookups 
> for your datasource strategy.  More importantly, with the local 
> datasources and localOjbConfigurer in use, Spring users can't use OJB's 
> different caching strategies.  Users are forced to use PerBroker.  In my 
> articles, I cover all of the above as well as getting back to JNDI 
> lookups for datasourcing and eliminating the need for the 
> localOjbConfigurer.  This in turn allows for proper use of OJB's caching 
> strategies.  Finally, I also include three complete sample applications 
> that are easy to use and 2 of the 3 have embedded databases.  So it's 
> all wrapped up.  Robert actually reviewed them before I posted them.
> 
> The other issue is that Robert's writeup that you have is slightly 
> outdated.  He is telling users to setup caching in OJB.properties 
> instead of repository.xml.  Robert himself wrote to me and told me there 
> were new setups in OJB 1.0.2 and higher, so I'm surprised that he hasn't 
> fixed this...
> 
> Jason
> 
> 
> Armin Waibel wrote:
> 
>> Jason McKerr wrote:
>>
>>> I have finished the third installment of connecting up Spring and 
>>> OJB.  This covers using non-local configurers (it eliminates the need 
>>> for ojbConfigurer) so that you can use JNDI data sources and caching 
>>> strategies other than Per Broker.
>>>
>>> Armin,  included is the text file that you asked for.
>>>
>>
>> Thanks again! I added your "Howto" to 1.0.x CVS branch. Will be 
>> included in 1.0.4.
>> http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-spring.xml?rev=1.1.2.1&only_with_tag=OJB_1_0_RELEASE&view=markup 
>>
>>
>> Ops, in OJB 1.1 trunk I found a Spring Howto by Robert S. Sfeir
>> http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-ojb-with-springframework.xml?rev=1.3&view=markup 
>>
>>
>> This stuff was checked in 7 month ago. Is it up to date? What's the 
>> difference compared with your articles?
>>
>> regards,
>> Armin
>>
>>
>>> Thanks,
>>>
>>> Jason
>>>
>>> Jason McKerr wrote:
>>>
>>>> Armin,
>>>>
>>>> I am just finishing up the third article today.  As soon as I get 
>>>> that done, I will write this and send along.
>>>>
>>>> Jason
>>>>
>>>> Armin Waibel wrote:
>>>>
>>>>> Hi Jason,
>>>>>
>>>>> Jason McKerr wrote:
>>>>>
>>>>>> Hi Thomas,
>>>>>>
>>>>>> If you guys want, feel free to take the two articles that I put up 
>>>>>> and move them into the How-to page.  I will have the third entry 
>>>>>> done in the next few days.
>>>>>>
>>>>>
>>>>> Thanks a lot!
>>>>> I will add your articles to OJB's Link page.
>>>>>
>>>>> Jason, if you send me a summing-up of your three articles as normal 
>>>>> .txt-file I will transform it to a forrest-compatible Howto and add 
>>>>> it to OJB-docs.
>>>>>
>>>>> regards,
>>>>> Armin
>>>>>
>>>>>
>>>>>> Jason
>>>>>>
>>>>>> Thomas Dudziak wrote:
>>>>>>
>>>>>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>>>>>  
>>>>>>>
>>>>>>>> I've finished the second (more simple) installment of Spring 
>>>>>>>> with OJB if
>>>>>>>> anyone is interested.
>>>>>>>>
>>>>>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>>>>>   
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> First off, thanks for sharing this with us ! I use OJB with 
>>>>>>> Spring for
>>>>>>> several months now, but never got around writing a tutorial for 
>>>>>>> it ;-)
>>>>>>> Just a quick comment: the separation that Matt made concerning DAOs
>>>>>>> and services is actually a really good idea because it separates
>>>>>>> concerns - your actions want to execute business logic not database
>>>>>>> accesses, and you can often want to combine several database 
>>>>>>> accesses
>>>>>>> into one business method. Also it greatly simplifies testing because
>>>>>>> you can replace the DAOs easily (by using a different
>>>>>>> applicationContext file) and thus test your services without 
>>>>>>> having to
>>>>>>> have a database at hand but instead against mock DAOs.
>>>>>>>
>>>>>>> Tom
>>>>>>>
>>>>>>> --------------------------------------------------------------------- 
>>>>>>>
>>>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>>>
>>>>>>>  
>>>>>>>
>>>>>>
>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>> Included are three articles that are in-depth How-to's for using 
>>> Spring Framework's declarative transaction engine with OJB's 
>>> Persistence Broker implementation.  For each article, I have included 
>>> a complete sample application with an embedded database that you can 
>>> run.  They are simple to setup and require minimal configuration.
>>>
>>> The first article covers a basic configuration and setup for 
>>> integrating Spring with OJB.  It covers:
>>> -Connecting to the database using Spring's local datasources 
>>> (LocalOjbConfigurer)
>>> -Register the appropriate transactionManager for use with OJB 
>>> (PersistenceBrokerTransactionManager)
>>> -Creating beans and interfaces for use with the database
>>> -Having Spring handle transactions for the beans in declarative fashion
>>>
>>> The article link is: http://staff.osuosl.org/~mckerrj/?p=3
>>>
>>> The second article covers more advanced Spring usage, separating out 
>>> the database implementation code from your Data Access Objects.  This 
>>> is an important abstraction layer for controlling data access 
>>> ubiquitously.
>>>
>>> The article is http://staff.osuosl.org/~mckerrj/?p=4
>>>
>>> The Third article covers using OJB's datasourcing and caching 
>>> strategies.  The first two articles require local datasources and Per 
>>> Broker caching because of the way that the OjbConfigurer works.  Now 
>>> that we've completed basics of integrating OJB in Spring, this last 
>>> entry shows how to use JNDI datasourcing with OJB and Spring, which 
>>> in turn allows users to get back to other OJB caching strategies.
>>>
>>> The article is: http://staff.osuosl.org/~mckerrj/?p=8
>>>
>>> Jason
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 3, Spring, Text file for Armin

Posted by Jason McKerr <ja...@osuosl.org>.
Hi Armin,

I read through the one that Robert did.  He actually helped me quite a 
bit with the three that I wrote.  There are a couple of important things 
there.

First, Robert's only covers configuration files.  Land while it does 
that well (and Robert helped me quite a bit with my config setup) it 
only covers the basics.  The three articles that I wrote covers 
configuration, interception patterns with DAO, OJB implementations, 
advanced DAO pattersn.  Also Robert's only covers local datasourcing 
using Springs local datasource and the localOJBConfigurer.  The problem 
with this is that it doesn't allow you to use server based/JNDI lookups 
for your datasource strategy.  More importantly, with the local 
datasources and localOjbConfigurer in use, Spring users can't use OJB's 
different caching strategies.  Users are forced to use PerBroker.  In my 
articles, I cover all of the above as well as getting back to JNDI 
lookups for datasourcing and eliminating the need for the 
localOjbConfigurer.  This in turn allows for proper use of OJB's caching 
strategies.  Finally, I also include three complete sample applications 
that are easy to use and 2 of the 3 have embedded databases.  So it's 
all wrapped up.  Robert actually reviewed them before I posted them.

The other issue is that Robert's writeup that you have is slightly 
outdated.  He is telling users to setup caching in OJB.properties 
instead of repository.xml.  Robert himself wrote to me and told me there 
were new setups in OJB 1.0.2 and higher, so I'm surprised that he hasn't 
fixed this...

Jason


Armin Waibel wrote:

> Jason McKerr wrote:
>
>> I have finished the third installment of connecting up Spring and 
>> OJB.  This covers using non-local configurers (it eliminates the need 
>> for ojbConfigurer) so that you can use JNDI data sources and caching 
>> strategies other than Per Broker.
>>
>> Armin,  included is the text file that you asked for.
>>
>
> Thanks again! I added your "Howto" to 1.0.x CVS branch. Will be 
> included in 1.0.4.
> http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-spring.xml?rev=1.1.2.1&only_with_tag=OJB_1_0_RELEASE&view=markup 
>
>
> Ops, in OJB 1.1 trunk I found a Spring Howto by Robert S. Sfeir
> http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-ojb-with-springframework.xml?rev=1.3&view=markup 
>
>
> This stuff was checked in 7 month ago. Is it up to date? What's the 
> difference compared with your articles?
>
> regards,
> Armin
>
>
>> Thanks,
>>
>> Jason
>>
>> Jason McKerr wrote:
>>
>>> Armin,
>>>
>>> I am just finishing up the third article today.  As soon as I get 
>>> that done, I will write this and send along.
>>>
>>> Jason
>>>
>>> Armin Waibel wrote:
>>>
>>>> Hi Jason,
>>>>
>>>> Jason McKerr wrote:
>>>>
>>>>> Hi Thomas,
>>>>>
>>>>> If you guys want, feel free to take the two articles that I put up 
>>>>> and move them into the How-to page.  I will have the third entry 
>>>>> done in the next few days.
>>>>>
>>>>
>>>> Thanks a lot!
>>>> I will add your articles to OJB's Link page.
>>>>
>>>> Jason, if you send me a summing-up of your three articles as normal 
>>>> .txt-file I will transform it to a forrest-compatible Howto and add 
>>>> it to OJB-docs.
>>>>
>>>> regards,
>>>> Armin
>>>>
>>>>
>>>>> Jason
>>>>>
>>>>> Thomas Dudziak wrote:
>>>>>
>>>>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>>>>  
>>>>>>
>>>>>>> I've finished the second (more simple) installment of Spring 
>>>>>>> with OJB if
>>>>>>> anyone is interested.
>>>>>>>
>>>>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>>>>   
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> First off, thanks for sharing this with us ! I use OJB with 
>>>>>> Spring for
>>>>>> several months now, but never got around writing a tutorial for 
>>>>>> it ;-)
>>>>>> Just a quick comment: the separation that Matt made concerning DAOs
>>>>>> and services is actually a really good idea because it separates
>>>>>> concerns - your actions want to execute business logic not database
>>>>>> accesses, and you can often want to combine several database 
>>>>>> accesses
>>>>>> into one business method. Also it greatly simplifies testing because
>>>>>> you can replace the DAOs easily (by using a different
>>>>>> applicationContext file) and thus test your services without 
>>>>>> having to
>>>>>> have a database at hand but instead against mock DAOs.
>>>>>>
>>>>>> Tom
>>>>>>
>>>>>> --------------------------------------------------------------------- 
>>>>>>
>>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>>
>>>>>>  
>>>>>>
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>
>>>>>
>>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>
>>
>>
>> ------------------------------------------------------------------------
>>
>> Included are three articles that are in-depth How-to's for using 
>> Spring Framework's declarative transaction engine with OJB's 
>> Persistence Broker implementation.  For each article, I have included 
>> a complete sample application with an embedded database that you can 
>> run.  They are simple to setup and require minimal configuration.
>>
>> The first article covers a basic configuration and setup for 
>> integrating Spring with OJB.  It covers:
>> -Connecting to the database using Spring's local datasources 
>> (LocalOjbConfigurer)
>> -Register the appropriate transactionManager for use with OJB 
>> (PersistenceBrokerTransactionManager)
>> -Creating beans and interfaces for use with the database
>> -Having Spring handle transactions for the beans in declarative fashion
>>
>> The article link is: http://staff.osuosl.org/~mckerrj/?p=3
>>
>> The second article covers more advanced Spring usage, separating out 
>> the database implementation code from your Data Access Objects.  This 
>> is an important abstraction layer for controlling data access 
>> ubiquitously.
>>
>> The article is http://staff.osuosl.org/~mckerrj/?p=4
>>
>> The Third article covers using OJB's datasourcing and caching 
>> strategies.  The first two articles require local datasources and Per 
>> Broker caching because of the way that the OjbConfigurer works.  Now 
>> that we've completed basics of integrating OJB in Spring, this last 
>> entry shows how to use JNDI datasourcing with OJB and Spring, which 
>> in turn allows users to get back to other OJB caching strategies.
>>
>> The article is: http://staff.osuosl.org/~mckerrj/?p=8
>>
>> Jason
>>
>>
>> ------------------------------------------------------------------------
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 3, Spring, Text file for Armin

Posted by Armin Waibel <ar...@apache.org>.
Jason McKerr wrote:
> I have finished the third installment of connecting up Spring and OJB.  
> This covers using non-local configurers (it eliminates the need for 
> ojbConfigurer) so that you can use JNDI data sources and caching 
> strategies other than Per Broker.
> 
> Armin,  included is the text file that you asked for.
>

Thanks again! I added your "Howto" to 1.0.x CVS branch. Will be included 
in 1.0.4.
http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-spring.xml?rev=1.1.2.1&only_with_tag=OJB_1_0_RELEASE&view=markup

Ops, in OJB 1.1 trunk I found a Spring Howto by Robert S. Sfeir
http://cvs.apache.org/viewcvs.cgi/db-ojb/src/doc/forrest/src/documentation/content/xdocs/docu/howtos/howto-use-ojb-with-springframework.xml?rev=1.3&view=markup

This stuff was checked in 7 month ago. Is it up to date? What's the 
difference compared with your articles?

regards,
Armin


> Thanks,
> 
> Jason
> 
> Jason McKerr wrote:
> 
>> Armin,
>>
>> I am just finishing up the third article today.  As soon as I get that 
>> done, I will write this and send along.
>>
>> Jason
>>
>> Armin Waibel wrote:
>>
>>> Hi Jason,
>>>
>>> Jason McKerr wrote:
>>>
>>>> Hi Thomas,
>>>>
>>>> If you guys want, feel free to take the two articles that I put up 
>>>> and move them into the How-to page.  I will have the third entry 
>>>> done in the next few days.
>>>>
>>>
>>> Thanks a lot!
>>> I will add your articles to OJB's Link page.
>>>
>>> Jason, if you send me a summing-up of your three articles as normal 
>>> .txt-file I will transform it to a forrest-compatible Howto and add 
>>> it to OJB-docs.
>>>
>>> regards,
>>> Armin
>>>
>>>
>>>> Jason
>>>>
>>>> Thomas Dudziak wrote:
>>>>
>>>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>>>  
>>>>>
>>>>>> I've finished the second (more simple) installment of Spring with 
>>>>>> OJB if
>>>>>> anyone is interested.
>>>>>>
>>>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>>>   
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> First off, thanks for sharing this with us ! I use OJB with Spring for
>>>>> several months now, but never got around writing a tutorial for it ;-)
>>>>> Just a quick comment: the separation that Matt made concerning DAOs
>>>>> and services is actually a really good idea because it separates
>>>>> concerns - your actions want to execute business logic not database
>>>>> accesses, and you can often want to combine several database accesses
>>>>> into one business method. Also it greatly simplifies testing because
>>>>> you can replace the DAOs easily (by using a different
>>>>> applicationContext file) and thus test your services without having to
>>>>> have a database at hand but instead against mock DAOs.
>>>>>
>>>>> Tom
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>>
>>>>>  
>>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
> 
> 
> ------------------------------------------------------------------------
> 
> Included are three articles that are in-depth How-to's for using Spring Framework's declarative transaction engine with OJB's Persistence Broker implementation.  For each article, I have included a complete sample application with an embedded database that you can run.  They are simple to setup and require minimal configuration.
> 
> The first article covers a basic configuration and setup for integrating Spring with OJB.  It covers:
> -Connecting to the database using Spring's local datasources (LocalOjbConfigurer)
> -Register the appropriate transactionManager for use with OJB (PersistenceBrokerTransactionManager)
> -Creating beans and interfaces for use with the database
> -Having Spring handle transactions for the beans in declarative fashion
> 
> The article link is: http://staff.osuosl.org/~mckerrj/?p=3
> 
> The second article covers more advanced Spring usage, separating out the database implementation code from your Data Access Objects.  This is an important abstraction layer for controlling data access ubiquitously.
> 
> The article is http://staff.osuosl.org/~mckerrj/?p=4
> 
> The Third article covers using OJB's datasourcing and caching strategies.  The first two articles require local datasources and Per Broker caching because of the way that the OjbConfigurer works.  Now that we've completed basics of integrating OJB in Spring, this last entry shows how to use JNDI datasourcing with OJB and Spring, which in turn allows users to get back to other OJB caching strategies.
> 
> The article is: http://staff.osuosl.org/~mckerrj/?p=8
> 
> Jason
> 
> 
> ------------------------------------------------------------------------
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 3, Spring, Text file for Armin

Posted by Jason McKerr <ja...@osuosl.org>.
I have finished the third installment of connecting up Spring and OJB.  
This covers using non-local configurers (it eliminates the need for 
ojbConfigurer) so that you can use JNDI data sources and caching 
strategies other than Per Broker.

Armin,  included is the text file that you asked for.

Thanks,

Jason

Jason McKerr wrote:

> Armin,
>
> I am just finishing up the third article today.  As soon as I get that 
> done, I will write this and send along.
>
> Jason
>
> Armin Waibel wrote:
>
>> Hi Jason,
>>
>> Jason McKerr wrote:
>>
>>> Hi Thomas,
>>>
>>> If you guys want, feel free to take the two articles that I put up 
>>> and move them into the How-to page.  I will have the third entry 
>>> done in the next few days.
>>>
>>
>> Thanks a lot!
>> I will add your articles to OJB's Link page.
>>
>> Jason, if you send me a summing-up of your three articles as normal 
>> .txt-file I will transform it to a forrest-compatible Howto and add 
>> it to OJB-docs.
>>
>> regards,
>> Armin
>>
>>
>>> Jason
>>>
>>> Thomas Dudziak wrote:
>>>
>>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>>  
>>>>
>>>>> I've finished the second (more simple) installment of Spring with 
>>>>> OJB if
>>>>> anyone is interested.
>>>>>
>>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>>   
>>>>
>>>>
>>>>
>>>>
>>>> First off, thanks for sharing this with us ! I use OJB with Spring for
>>>> several months now, but never got around writing a tutorial for it ;-)
>>>> Just a quick comment: the separation that Matt made concerning DAOs
>>>> and services is actually a really good idea because it separates
>>>> concerns - your actions want to execute business logic not database
>>>> accesses, and you can often want to combine several database accesses
>>>> into one business method. Also it greatly simplifies testing because
>>>> you can replace the DAOs easily (by using a different
>>>> applicationContext file) and thus test your services without having to
>>>> have a database at hand but instead against mock DAOs.
>>>>
>>>> Tom
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>
>>>>  
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
>


Re: Installment 2, Spring

Posted by Armin Waibel <ar...@apache.org>.
Jason McKerr wrote:
> Armin,
> 
> I am just finishing up the third article today.  As soon as I get that 
> done, I will write this and send along.
>

Great!

Armin


> Jason
> 
> Armin Waibel wrote:
> 
>> Hi Jason,
>>
>> Jason McKerr wrote:
>>
>>> Hi Thomas,
>>>
>>> If you guys want, feel free to take the two articles that I put up 
>>> and move them into the How-to page.  I will have the third entry done 
>>> in the next few days.
>>>
>>
>> Thanks a lot!
>> I will add your articles to OJB's Link page.
>>
>> Jason, if you send me a summing-up of your three articles as normal 
>> .txt-file I will transform it to a forrest-compatible Howto and add it 
>> to OJB-docs.
>>
>> regards,
>> Armin
>>
>>
>>> Jason
>>>
>>> Thomas Dudziak wrote:
>>>
>>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>>  
>>>>
>>>>> I've finished the second (more simple) installment of Spring with 
>>>>> OJB if
>>>>> anyone is interested.
>>>>>
>>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>>   
>>>>
>>>>
>>>>
>>>>
>>>> First off, thanks for sharing this with us ! I use OJB with Spring for
>>>> several months now, but never got around writing a tutorial for it ;-)
>>>> Just a quick comment: the separation that Matt made concerning DAOs
>>>> and services is actually a really good idea because it separates
>>>> concerns - your actions want to execute business logic not database
>>>> accesses, and you can often want to combine several database accesses
>>>> into one business method. Also it greatly simplifies testing because
>>>> you can replace the DAOs easily (by using a different
>>>> applicationContext file) and thus test your services without having to
>>>> have a database at hand but instead against mock DAOs.
>>>>
>>>> Tom
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>>
>>>>  
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Jason McKerr <ja...@osuosl.org>.
Armin,

I am just finishing up the third article today.  As soon as I get that 
done, I will write this and send along.

Jason

Armin Waibel wrote:

> Hi Jason,
>
> Jason McKerr wrote:
>
>> Hi Thomas,
>>
>> If you guys want, feel free to take the two articles that I put up 
>> and move them into the How-to page.  I will have the third entry done 
>> in the next few days.
>>
>
> Thanks a lot!
> I will add your articles to OJB's Link page.
>
> Jason, if you send me a summing-up of your three articles as normal 
> .txt-file I will transform it to a forrest-compatible Howto and add it 
> to OJB-docs.
>
> regards,
> Armin
>
>
>> Jason
>>
>> Thomas Dudziak wrote:
>>
>>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>>  
>>>
>>>> I've finished the second (more simple) installment of Spring with 
>>>> OJB if
>>>> anyone is interested.
>>>>
>>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>>   
>>>
>>>
>>>
>>> First off, thanks for sharing this with us ! I use OJB with Spring for
>>> several months now, but never got around writing a tutorial for it ;-)
>>> Just a quick comment: the separation that Matt made concerning DAOs
>>> and services is actually a really good idea because it separates
>>> concerns - your actions want to execute business logic not database
>>> accesses, and you can often want to combine several database accesses
>>> into one business method. Also it greatly simplifies testing because
>>> you can replace the DAOs easily (by using a different
>>> applicationContext file) and thus test your services without having to
>>> have a database at hand but instead against mock DAOs.
>>>
>>> Tom
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>>
>>>  
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Armin Waibel <ar...@apache.org>.
Hi Jason,

Jason McKerr wrote:
> Hi Thomas,
> 
> If you guys want, feel free to take the two articles that I put up and 
> move them into the How-to page.  I will have the third entry done in the 
> next few days.
>

Thanks a lot!
I will add your articles to OJB's Link page.

Jason, if you send me a summing-up of your three articles as normal 
.txt-file I will transform it to a forrest-compatible Howto and add it 
to OJB-docs.

regards,
Armin


> Jason
> 
> Thomas Dudziak wrote:
> 
>> On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>>  
>>
>>> I've finished the second (more simple) installment of Spring with OJB if
>>> anyone is interested.
>>>
>>> http://staff.osuosl.org/~mckerrj/?p=4
>>>   
>>
>>
>> First off, thanks for sharing this with us ! I use OJB with Spring for
>> several months now, but never got around writing a tutorial for it ;-)
>> Just a quick comment: the separation that Matt made concerning DAOs
>> and services is actually a really good idea because it separates
>> concerns - your actions want to execute business logic not database
>> accesses, and you can often want to combine several database accesses
>> into one business method. Also it greatly simplifies testing because
>> you can replace the DAOs easily (by using a different
>> applicationContext file) and thus test your services without having to
>> have a database at hand but instead against mock DAOs.
>>
>> Tom
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: ojb-user-help@db.apache.org
>>
>>  
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Jason McKerr <ja...@osuosl.org>.
Hi Thomas,

If you guys want, feel free to take the two articles that I put up and 
move them into the How-to page.  I will have the third entry done in the 
next few days.

Jason

Thomas Dudziak wrote:

>On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
>  
>
>>I've finished the second (more simple) installment of Spring with OJB if
>>anyone is interested.
>>
>>http://staff.osuosl.org/~mckerrj/?p=4
>>    
>>
>
>First off, thanks for sharing this with us ! I use OJB with Spring for
>several months now, but never got around writing a tutorial for it ;-)
>Just a quick comment: the separation that Matt made concerning DAOs
>and services is actually a really good idea because it separates
>concerns - your actions want to execute business logic not database
>accesses, and you can often want to combine several database accesses
>into one business method. Also it greatly simplifies testing because
>you can replace the DAOs easily (by using a different
>applicationContext file) and thus test your services without having to
>have a database at hand but instead against mock DAOs.
>
>Tom
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
>For additional commands, e-mail: ojb-user-help@db.apache.org
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Installment 2, Spring

Posted by Thomas Dudziak <to...@gmail.com>.
On 6/24/05, Jason McKerr <ja...@osuosl.org> wrote:
> I've finished the second (more simple) installment of Spring with OJB if
> anyone is interested.
> 
> http://staff.osuosl.org/~mckerrj/?p=4

First off, thanks for sharing this with us ! I use OJB with Spring for
several months now, but never got around writing a tutorial for it ;-)
Just a quick comment: the separation that Matt made concerning DAOs
and services is actually a really good idea because it separates
concerns - your actions want to execute business logic not database
accesses, and you can often want to combine several database accesses
into one business method. Also it greatly simplifies testing because
you can replace the DAOs easily (by using a different
applicationContext file) and thus test your services without having to
have a database at hand but instead against mock DAOs.

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org