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

Jordan West commented on CASSANDRA-14285:
-----------------------------------------

+1. As an added bonus it also fixes the case where there is a double comma in 
the string. Don't see an interpretation of the config where the operator 
intended to include localhost as a seed so I think the "breaking" change is a 
good one (i.e no one should be expecting this behavior). Since its breaking, I 
guess we can ignore back porting to 3.11 – the patch doesn't apply clean 
either. 

I wanted to ask you to add a test but it looks like that will be a pain given 
how {{SimpleSeedProvider}} is currently implemented.

Branch: [https://github.com/jrwest/cassandra/tree/14285-trunk]

utests: [https://circleci.com/gh/jrwest/cassandra/37]

 

> Comma at the end of the end of the seed list is interpretated as localhost
> --------------------------------------------------------------------------
>
>                 Key: CASSANDRA-14285
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-14285
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Configuration
>            Reporter: Marco
>            Priority: Minor
>
> Seeds: '10.1.20.10,10.1.21.10,10.1.22.10,'  cause a flood of the debug log 
> with messages like this one.
> DEBUG [MessagingService-Outgoing-localhost/127.0.0.1-Gossip] 2018-02-28 
> 15:53:57,314 OutboundTcpConnection.java:545 - Unable to connect to 
> localhost/[127.0.0.1|http://127.0.0.1/]
> This code provide by Nicolas Guyomar provide the reason of the issue.
> In SImpleSeedProvider : 
>  
> String[] hosts = "10.1.20.10,10.1.21.10,10.1.22.10,".split(",", -1);
> List<InetAddress> seeds = new ArrayList<InetAddress>(hosts.length);
> for (String host : hosts)
> {
> System.out.println(InetAddress.getByName(host.trim()));
> }
>  
> output : 
> /[10.1.20.10|http://10.1.20.10/]
> /[10.1.21.10|http://10.1.21.10/]
> /[10.1.22.10|http://10.1.22.10/]
> localhost/[127.0.0.1|http://127.0.0.1/]



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

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to