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

Incorrect remote partitioning sample in the documentation [BATCH-2730] #875

Closed
spring-issuemaster opened this issue Jun 8, 2018 · 0 comments
Closed

Comments

@spring-issuemaster
Copy link
Collaborator

@spring-issuemaster spring-issuemaster commented Jun 8, 2018

Mahmoud Ben Hassine opened BATCH-2730 and commented

There are some minor errors in the remote partitioning section of the documentation. The code example of the partitioned step is incorrect:

public Job personJob() {
                return jobBuilderFactory.get("personJob")
                                .start(stepBuilderFactory.get("step1.master")
                                                .partitioner(partitionHandler())
                                                .build())
                                .build();
 }

while it should be:

public Job personJob() {
                return jobBuilderFactory.get("personJob")
                                .start(stepBuilderFactory.get("step1.master")
                                                .partitioner("step1.worker", partitioner())
                                                .partitionHandler(partitionHandler())
                                                .build())
                                .build();
 }

Moreover, the code example shows all beans in the same bloc without mentioning which ones should be declared on the master side and which ones should be declared on the worker side. This is confusing. It should either use profiles or separate the master's configuration from the worker's configuration.

Finally, it would be great to add a remote partitioning sample to the spring-batch-samples module (current samples show only local partitioning).


Affects: 4.0.1, 4.1.0.M1

Referenced from: pull request #612, and commits 5730f38, 2c5b7b5

Backported to: 4.0.2

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.