Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slightly confusing use of *Dao in sample configuration in documentation, where *ItemWriter would be clearer [BATCH-993] #2584

Closed
spring-issuemaster opened this issue Jan 12, 2009 · 1 comment

Comments

@spring-issuemaster
Copy link
Collaborator

@spring-issuemaster spring-issuemaster commented Jan 12, 2009

David J. M. Karlsen opened BATCH-993 and commented

The documentation at http://static.springframework.org/spring-batch/1.1.x/spring-batch-docs/reference/html-single/index.html

reads:

<bean id="hibernateItemWriter"
class="org.springframework.batch.item.database.HibernateAwareItemWriter">
<property name="sessionFactory" ref="sessionFactory" />
<property name="delegate" ref="customerCreditWriter" />
</bean>

<bean id="customerCreditWriter"
class="org.springframework.batch.sample.dao.HibernateCreditDao">
<property name="sessionFactory" ref="sessionFactory" />
</bean>

which is not correct - the delegate must be an ItemWriter - not a plain dao: http://static.springframework.org/spring-batch/1.1.x/apidocs/org/springframework/batch/item/database/HibernateAwareItemWriter.html#setDelegate(org.springframework.batch.item.ItemWriter)


Affects: 1.1.3, 2.0.0.M3

Backported to: 1.1.4

@spring-issuemaster
Copy link
Collaborator Author

@spring-issuemaster spring-issuemaster commented Jan 12, 2009

Dave Syer commented

I'll change it in the docs, but note that the HibernateCreditDao in the samples is actually an ItemWriter (I won't be changing that for a point release).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.