flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tillrohrmann <...@git.apache.org>
Subject [GitHub] flink pull request #2245: [hotfix] Fix Redis Sink to fail at opening if Redi...
Date Mon, 18 Jul 2016 14:29:16 GMT
Github user tillrohrmann commented on a diff in the pull request:

    https://github.com/apache/flink/pull/2245#discussion_r71156944
  
    --- Diff: flink-streaming-connectors/flink-connector-redis/src/main/java/org/apache/flink/streaming/connectors/redis/RedisSink.java
---
    @@ -166,7 +166,13 @@ public void invoke(IN input) throws Exception {
          */
     	@Override
     	public void open(Configuration parameters) throws Exception {
    -		this.redisCommandsContainer = RedisCommandsContainerBuilder.build(this.flinkJedisConfigBase);
    +		try {
    +			this.redisCommandsContainer = RedisCommandsContainerBuilder.build(this.flinkJedisConfigBase);
    +			this.redisCommandsContainer.open();
    +		} catch (Exception e) {
    +			LOG.error("Redis has not been properly initialized.");
    --- End diff --
    
    The exception should be logged here as well.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message