Better HN
topnewbestaskshowjobs
Log inSign up

StabbyCutyou

121 karma · joined May 13, 2015 (11y ago) · 27 submissions

Submissions

comment 5y ago · link · parent

Thanks! In terms of backend engineering, I'd say one of the trickiest things is always depending deeply on a third party service or provider to be the backbone of the value you add.

That's a pretty high level answer, but in general that's the most difficult to wrangle with over time, in my opinion.

To give a more concrete answer, every slack instance and the way people configure it can be a little different, and in some cases we found it tricky to find the right consistent location to pull information like display names from.

In terms of what is unexpectedly easy, Slack themselves been great at giving us feedback and advice for building on their platform!

comment 5y ago · link · parent

Yes! Right now we have a PD integration that will allow us to receive your alerts, and once you bind them to an Allma Incident, manage the alerts for you as well!

comment 5y ago · link · parent

Hey folks! I'm Sean, the CTO of Allma.

Would love to chat about the product if folks have any questions!

comment 9y ago · link · parent

So, specifically in the context of a distributed queue (which, if we're talking about using MS arch + queueing due to scale concerns, you really need some kind of distribution to the message queue imo), these things get a lot harder.

Just because TCP provides resilience doesn't mean that you're perfectly defended against all kinds of issues here.

I'm mostly talking about things in the category of bugs in the software layer using TCP (the drivers, the consumers/publishers, race conditions, batching messages, not receiving ACKs, etc). There are a lot of little things that can go wrong.

In terms of partitions, look up a series by a guy named Aphyr called "Jepsen". It goes over the CAP theorem as it applies to distributed datastores and queues. His examples and tests will demonstrate the concepts behind partitioning better than I can explain over a HN comment :)

And yes, these types of failures are implicit everywhere - but every additional layer you add, every hop in the chain, every interaction added to the request flow increases the surface area for problems. Especially once you push high scale with hundreds of nodes, become nic or cpu bound, etc etc.

There is a lot to unpack here, and it's not as simple as it seems on the face of it.

comment 9y ago · link · parent

This is more of the intended audience (earlier startups or smaller groups of devs), but I could have done a better job spelling that out.

comment 9y ago · link · parent

The accuracy of this statement is as depressing as it is apt.

comment 9y ago · link · parent

Thanks for adding some historical context for me!

comment 9y ago · link · parent

I didn't discuss queues because queues aren't intrinsically a part of a MS architecture.

You certainly can do it that way, and there are lots of benefits, but queues (and if you're doing this at scale, distributed queues) are an entirely distinct subject matter that I chose not to touch on for this.

Also, things can still get lost with queues. Network failures, partitions, bugs in your own publishers and consumers... nothing is fool-proof, and it takes a lot of work to reduce that loss rate to 0.

comment 9y ago · link · parent

Hello all you nice folks on HN. Original author of the article here. A few things I'd like to add, since this is essentially what feedback I get every time this has made the rounds:

1. I don't think microservices are bad, or that they don't work. Quite the contrary. My argument is simply that there is a lot of additional complexity in using this approach to your architecture, and to consider if you're able to handle that before diving in.

2. This was adapted from a lightning talk I gave almost 2 years ago, and is almost by-design light on hard details or deep dives. It was meant to just introduce the problems by talking about fallacies (which many think are strawmen, but they're arguments that i've heard from people in my own discussions on the subject).

3. Even if you disagree with my points, I appreciate folks taking the time to read and provide feedback.

Thanks!

comment 9y ago · link · parent

Hi, original author here!

Quickly, on the "elementary" nature of the post, this was adapted from a lightning talk I gave, and so it was sort of designed to be a very quick introduction into the problem space.

Also this was meant to be (and this is my own fault for maybe not more carefully spelling this out) aimed at people just starting out with a new project or endeavor, as a warning that "just sprinkling some microservices on it" is not a magical panacea for scalability or good software design.

Thanks for taking the time to read and comment!

11.

Early Warning Detectors Using AWS Access Keys as Honeytokens(blog.komand.com ↗)

160 points · by StabbyCutyou · 10y ago · 19 comments

comment 10y ago · link · parent

Elegant, simple, and idiomatic.

The perfect solution for Go.

comment 10y ago · link · parent

This is definitely one of the main takeaways that I wanted to get across.

comment 10y ago · link · parent

Well said, thanks!

comment 10y ago · link · parent

I do wish I had titled it better, as most people have (rightfully) dinged me on this one ;)

comment 10y ago · link · parent

One of the downsides of the blog post was that I adapted it from a lightning talk, so it was meant to be a little content-light, but to put ideas in peoples minds around how to think about the tradeoffs.

For example, your point about Go vs Rails is an apt one - I would only add that I made that comparison because...

A: It was originally a golang meetup where I gave the talk B: Go is increasingly becoming popular as a choice people move to off of Rails, for performance sensitive code (Scala being the other popular choice I see), and also for building "microservices" themselves.

I could have, and maybe should have, gone a little more in depth at that part, but the idea wasn't to be fully exhaustive (for better or worse).

But the main takeaway about the performance gains was that the idea of putting the word "micro" in front of something magically made it more performant without appreciating why. It's a response to folks simply parroting information without understanding it.

Thanks for the feedback.

comment 10y ago · link · parent

You have a good point in that in the early stages, any app is likely not to be a "monolith", but it's less about size/LOC and more about the design ethic of the architecture itself.

If you build your codebase internally with service level abstractions in mind, you can gain a lot of benefit without the cost of the network or the additional errors it can introduce.

Thanks for reading!

comment 10y ago · link · parent

Author here - your ninja edit is one of the core premises of the entire post.

Some other folks have addressed the scalability questions you raised, but i'd add - I am in no way advocating for monoliths as a better approach. Rather, both have tradeoffs you need to think through before adopting.

Thanks for taking the time read.

comment 10y ago · link · parent

I appreciate the feedback, but unfortunately I think you've made a bit of a leap in terms of what my point here was.

It isn't that i'm saying "Don't build microservices", but rather "Don't adopt this approach until you understand the tradeoffs involved". I've worked on teams that have done it well, and not done it well. I've worked with large codebases that are well maintained, and poorly maintained. There are tradeoffs that need to be taken into consideration before adopting any major architectural approach.

I will say that upon reflection, the original title could have been reworded a bit to better express this.

comment 10y ago · link · parent

Hi, author here - thanks for taking the time read it.

You're not wrong in that this article is meant to point out the pitfalls of the approach, and to advocate for understanding before diving into a particular architecture.

It's meant to give people things to consider before deciding breaking things into "microservices" is the right thing for their engineering org at that time.

I attempted to note several times that my intention was not to say "Microservices are bad", but rather "Please don't dive in before you consider the trade offs". It's not as simple as some folks might have you believe, so I felt it was valuable to have a "lessons learned" type retrospective coming from someone who has been involved in both approaches.

Thanks for the feedback.

comment 10y ago · link · parent

Author here - Came to reply with basically what you just said.

Thanks for giving it a read!

comment 10y ago · link · parent

Well...

Guess I need to rename https://github.com/StabbyCutyou/0db

23.

Moldova – A utility for generating random data based on templated input(github.com ↗)

1 points · by StabbyCutyou · 10y ago · discuss

comment 11y ago · link · parent

They actually would let you increase that, but only up to a certain point and only if you specifically requested it. I don't see them mention the absolute ceiling being lifted, so that is probably still in place somewhere.

I'd wager it's more likely that read-after-write change.

comment 11y ago · link · parent

I notice you're using interfaces to do your handlers, and (forgive me if i'm reading this wrong) casting those interfaces to a specific "type" of function before invoking them.

That seems like it would be inefficient in performance-critical code like a worker system. Have you considered using typed-functions and function pointers to accomplish a similar approach?

That said, I could easily be missing something in the design, so feel free to correct me if I'm wrong.

26.

BuffStreams – Streaming Protocol Buffers messages over TCP in Go(github.com ↗)

10 points · by StabbyCutyou · 11y ago · discuss

comment 11y ago · link · parent

Hi, thanks for the feedback.

Before I respond, let me say that I'm one of the core developers of the system, and that I am a big fan of Redis, and conceptually of Beanstalkd (never used it, but I know someone who is a big fan of it).

The reason you wouldn't use Redis of Beanstalkd is because they are inherently singular systems - Things exist to make them behave in a distributed fashion (for Redis, anyways - not sure about Beanstalkd?), but they are not. You're not going to scale them past a single box / node (although I will admit, I am not up on my Beanstalkd news, so possibly they've made strides there?).

Dynamiq leverages the amazing work done by Basho to build a rock solid distributed data store. By providing a light layer of coordination and logic at the edge of the system, it allows you to treat Riak (in all of it's AP glory) as something like a queue (this dovetails into your question about order, below). Riak is distributed to the core, and Dynamiq uses that to it's advantage. Need more capacity? Add more nodes. It'll handle the rest.

On the subject of dupes, they are technically "rare" once the system is running at an even keel. Only when nodes enter / leave or when you alter the configuration of a queue will you be likely to see dupes. Otherwise, the only "dupes" you'd see would be when the timeout expires and "out for delivery" messages become naturally available again (but we do not consider those "dupes").

The system in no way shape or form guarantees, offers, or even implies order. You will likely get a very loose order so long as you are always keeping up with the rate of messages in, but thats it. Never assume order, and in general you should strive to build systems that are resilient in the face of a lack of order.

The range scan operates over an ID that Dynamiq itself assigns to the message, by generating a random int64 using the golang secure/crypto library. The client cannot specify the ID. However, and this is what we do internally, we assign the message an internal, application specific ID prior to publishing it to Dynamiq. So each message ultimately ends up with 2 IDs - 1 for Dynamiqs own use, which you use to ACK once you're done, and one application specific ID which may or may not mean anything to the consuming service.