[ 
https://issues.apache.org/jira/browse/FLINK-8655?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16370581#comment-16370581
 ] 

ASF GitHub Bot commented on FLINK-8655:
---------------------------------------

GitHub user Bekreth opened a pull request:

    https://github.com/apache/flink/pull/5538

    [FLINK-8655] [DataSink] Added default keyspace to CassandraPojoSink

    ## What is the purpose of the change
    
    Initial Issue : [https://issues.apache.org/jira/browse/FLINK-8655]
    It is not uncommon for users to have a single Cassandra instance for all of 
their test environments, differentiating what each environment uses based on 
keyspace.  This PR adds functionality for the CassandraPojoSink to have the 
keyspace defined at runtime to allow for more flexible configurations.
    
    ## Brief change log
    
      - Added functionality for defining default keyspace at runtime.
    
    ## Verifying this change
    
    The changes have been verified manually.  Unit tests will be included 
following preliminary discussion on the functionality.
    
    ## Does this pull request potentially affect one of the following parts:
    
      - Dependencies (does it add or upgrade a dependency): no
      - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: no
      - The serializers: no
      - The runtime per-record code paths (performance sensitive): no
      - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Yarn/Mesos, ZooKeeper: no
      - The S3 file system connector: no
    
    ## Documentation
    
      - Does this pull request introduce a new feature? yes
      - If yes, how is the feature documented? JavaDocs

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/Bekreth/flink cassandraDefaultKeyspaceSink

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/5538.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #5538
    
----
commit bbf52274ba46da005894c1f7c4be4860cd619280
Author: chugh13 <christopher.hughes@...>
Date:   2018-02-20T20:02:11Z

    Added method to specify the keyspace that POJOs should be written to by 
default.

commit 0e014aefbb7cccf0e1d8caed50f2a9dc88962d4f
Author: chugh13 <christopher.hughes@...>
Date:   2018-02-20T20:37:17Z

    Added Javadocs and log messages to the defaultKeyspace feature

----


> Add a default keyspace to CassandraSink
> ---------------------------------------
>
>                 Key: FLINK-8655
>                 URL: https://issues.apache.org/jira/browse/FLINK-8655
>             Project: Flink
>          Issue Type: Improvement
>    Affects Versions: 1.4.0
>            Reporter: Christopher Hughes
>            Priority: Minor
>              Labels: features
>             Fix For: 1.5.0
>
>
> Currently, to use the CassandraPojoSink, it is necessary for a user to 
> provide keyspace information on the desired POJOs using datastax annotations. 
>  This allows various POJOs to be written to multiple keyspaces while sinking 
> messages, but prevent runtime flexibility.
> For many developers, non-production environments may all share a single 
> Cassandra instance differentiated by keyspace names.  I propose adding a 
> `defaultKeyspace(String keyspace)` to the ClusterBuilder.  POJOs lacking a 
> definitive keyspace would attempt to be loaded to the provided default.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to