[
https://issues.apache.org/jira/browse/BLUR-54?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13593550#comment-13593550
]
Gagan Deep Juneja commented on BLUR-54:
---------------------------------------
As per my understanding the issue here is that, If I am passing invalid shard
index then exception is thrown while creating connection stating error message
that "Connection string of [null] does not match 'host1:port' or
'host1:port/proxyhost1:proxyport'". Which is not correct one so we should
handle this scenario while creating the object for TableLayout where we
implement findServer() method to return the connectionString because this will
be null in our scenario and we should throw Runtime Exception here stating that
"Invalid ShardId is passed".
Almost all the methods those are calling getConnection() method in BlurServer
are wrapping all the Exceptions in BException and throwing.
We can throw BException from findServer method as well instead of
RuntimeException.
Please provide your inputs.
Regards,
Gagan
> Improve the error when a bad shard index is provided.
> -----------------------------------------------------
>
> Key: BLUR-54
> URL: https://issues.apache.org/jira/browse/BLUR-54
> Project: Apache Blur
> Issue Type: Bug
> Affects Versions: 0.2.0
> Reporter: Tim Williams
> Priority: Trivial
>
> Currently, if a client passes an unknown shard index, they get a message
> about a bad connection string when in fact that's just a side effect. I'm
> thinking that the TableLayout implemented in ThriftBlurServer should throw a
> RuntimeException if it isn't found - because that's where we have some useful
> context. Sound reasonable? Another option is to throw it in BlurServer's
> getConnection.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira