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

Acknowledge method in SQLService is always called #8

Closed
nhuray opened this issue Jul 11, 2012 · 1 comment
Closed

Acknowledge method in SQLService is always called #8

nhuray opened this issue Jul 11, 2012 · 1 comment

Comments

@nhuray
Copy link
Contributor

nhuray commented Jul 11, 2012

The acknowledge method in SQLService is always called even if the rivertable parameter is set to false (Managing updates with Elasticsearch versioning).

Indeed the BulkOperation is always created with a BulkAcknowledge :

 operation = new BulkOperation(client, logger).setIndex(indexName).setType(typeName).setVersioning(versioning)
                .setBulkSize(bulkSize).setMaxActiveRequests(maxBulkRequests)
                .setMillisBeforeContinue(bulkTimeout.millis()).setAcknowledge(riverName.getName(), service);

we have to replace it by this code :

 operation = new BulkOperation(client, logger).setIndex(indexName).setType(typeName).setVersioning(versioning)
                .setBulkSize(bulkSize).setMaxActiveRequests(maxBulkRequests)
                .setMillisBeforeContinue(bulkTimeout.millis()).setAcknowledge(riverName.getName(), rivertable ? service : null);
@jprante jprante closed this as completed Jul 11, 2012
@jprante
Copy link
Owner

jprante commented Jul 11, 2012

Thank you, good catch!

nhuray pushed a commit to nhuray/elasticsearch-river-jdbc that referenced this issue Jul 11, 2012
- Set acknowledge if rivertable is set to true
- Move housekeeper method in JDBCConnector
jprante added a commit that referenced this issue Jul 11, 2012
Fix #8 : Acknowledge method in SQLService is always called
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants