Hacker News new | ask | show | jobs
by equark 5438 days ago
Thanks for the detailed response. First, I'm glad you guys are doing this. It's great, I didn't mean to be overly negative.

I'd just lean towards having sensible defaults, so that first experience is:

var client = new RiakClient()

I just get nervous when I see what seems like should being a very simple API using ConnectionFactory and company.

2 comments

I agree with the point about the ConnectionFactory. That is something I still don't like. It's there, at the moment, to make it easy to test certain parts of the app. We'll look to add an overload to this so that we don't have to specify it for non-testing scenarios.

As a quick side-node something as simple as:

    var client = new RiakClient();
is nice, but has to infer a _lot_ from the world. We could write a lot of code to make sure that it's smart enough to pull all the details from the default locations or we could let people tell us where to look. We went for the latter, as it's much safer to be told than to pull config from the wrong spot.

Again, we'll look to improve this, particularly as we get more feedback from people using the library.

Thanks!

equark,

I don't think you were being overly negative. It just tends to be common for people on HN to be more terse than necessary and sometimes things can come across the wrong way. I have taken no offense :)

The sensible defaults thing is definitely something that should be in place. For v0.1.0, the goal was to provide the flexibility out of the box rather than the lack thereof. No doubt for v0.2.0 (already in the works) we'll have adjusted this to make it simpler for the more common cases. We didn't want to limit people out of the box.

Configuration of this kind of thing is hard when you can technically have multiple clusters, so somewhere along the way when wiring up the cluster you do need to specify something :)

At least we have the ability to do whatever we need. Now, with help from the community, users, and commenters like yourself, we can improve things to keep as many people happy as we can.

Thanks again for the comment.