You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/06/21 18:41:38 UTC

[GitHub] [pulsar] AlimZanibekov opened a new pull request #7329: Added ability to delete and update records in ElasticSearch sink connector

AlimZanibekov opened a new pull request #7329:
URL: https://github.com/apache/pulsar/pull/7329


   ### Motivation
   I need to use ElasticSearch via Pulsar as a database but not as a dump of logs that’s why I implemented the possibility to update and delete records, as well as to set id when creating a record
   
   ### Modifications
   Record processing
     - added "*ACTION*" [Record] property which can be "*UPSERT*" or "*DELETE*", default value is "*UPSERT*"
     - added "*ID*" [Record] property which provides record id (required for "*DELETE*")
   
   Tests
     -  added *updateSingleRecordTest*
     -  added *deleteSingleRecordTest*
     -  renamed *singleRecordTest-> insertSingleRecordTest*
   
   ### Verifying this change
   This change added tests and can be verified as follows:
     - *Extended unit tests (ElasticSearchSinkTests) for update and delete requests*
   
   ### Does this pull request potentially affect one of the following parts:
     - Dependencies (does it add or upgrade a dependency): no
     - The public API: no
     - The schema: no
     - The default values of configurations: no
     - The wire protocol: no
     - The rest endpoints: no
     - The admin cli options: no
     - Anything that affects deployment: don't know
   
   ### Documentation
   
     - Does this pull request introduce a new feature: yes 
     - Is the feature documented: not documented
   > I didn't find a documentation section for sink [Record] interface
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] eolivelli commented on pull request #7329: Added ability to delete and update records in ElasticSearch sink connector

Posted by GitBox <gi...@apache.org>.
eolivelli commented on pull request #7329:
URL: https://github.com/apache/pulsar/pull/7329#issuecomment-899412137


   This patch is probably superseded by the recent changes in the ElasticSearch connector.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] github-actions[bot] commented on pull request #7329: Added ability to delete and update records in ElasticSearch sink connector

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #7329:
URL: https://github.com/apache/pulsar/pull/7329#issuecomment-1058899585


   @alim-zanibekov:Thanks for your contribution. For this PR, do we need to update docs?
   (The [PR template contains info about doc](https://github.com/apache/pulsar/blob/master/.github/PULL_REQUEST_TEMPLATE.md#documentation), which helps others know more about the changes. Can you provide doc-related info in this and future PR descriptions? Thanks)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] sijie commented on pull request #7329: Added ability to delete and update records in ElasticSearch sink connector

Posted by GitBox <gi...@apache.org>.
sijie commented on pull request #7329:
URL: https://github.com/apache/pulsar/pull/7329#issuecomment-652780937


   @codelipenghui can you review this again?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] codelipenghui commented on a change in pull request #7329: Added ability to delete and update records in ElasticSearch sink connector

Posted by GitBox <gi...@apache.org>.
codelipenghui commented on a change in pull request #7329:
URL: https://github.com/apache/pulsar/pull/7329#discussion_r446472667



##########
File path: pulsar-io/elastic-search/src/main/java/org/apache/pulsar/io/elasticsearch/ElasticSearchSink.java
##########
@@ -66,6 +69,11 @@
     private CredentialsProvider credentialsProvider;
     private ElasticSearchConfig elasticSearchConfig;
 
+    protected static final String ACTION = "ACTION";

Review comment:
       It's better to add a prefix for the property name e.g. (ELASTCSEARCH_ACTION).




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org