78 karma · joined December 22, 2016
Tractors don't go _that_ fast but I'm not sure I'd rely on it in an actual car for anything but slightly better GPS.
Sure we can segment this into code generation models and code review models but are engineers really going to want to be questioned by a code review tool on "what are you trying to do?" or are they just going to merge and pull the slot lever again?
Sure we can use an LLM but I can for now click around faster (if those breadcrumbs exist) than it can reason.
Also the LLM would only point to a direction and I’m still going to have to use the UI to confirm.
Here were some of my consideration points against a generator (I had a list for batteries too):
1. the previous owners electrified the house so having a tank just for a generator didn't make sense
2. per 1, a small tank wouldn't last very long and if we're out of power for multiple days gas delivery is unlikely to be happening anyway.
3. tank + generator didn't have a practical placement location for us
4. smaller portable generators didn't make sense from a maintenance perspective since they didn't auto test.
5. what happens if it fails a self test right before a storm?
6. we get intermittent power cuts / fluctuations / outages throughout the year and the generator + ATS wouldn't protect sensitive electronics well
Edit: ATS + batteries can play nice together then I might look at doing a small portable as aux backup
I highly doubt that. Maybe there will be an evolution to k8s but fundamentally it solves a whole host of challenges around defining the environment an application runs in.
The issue we've ran into is some team at work decides to re-write an entire table and things get backed up until they stop updating rows.
- Connection pooling / pipelining and circuit breaking is a must at scale. The clients are a lot better than they used to be but it's important developers understand the behavior of the client library they are using. Someone suggested using Envoy as sidecar proxy, I personally wouldn't after our experience with it with redis but it's an easy option. - Avoid changing the cluster topology if the CPU load is over 40%. This is primarily in case of unplanned failures during a change. - If something goes wrong shed load application side as quick as possible because Redis won't recover if it's being hammered. You'll need to either have feature flags of be able to scale down your application. - Having replicas won't protect you from data loss so don't treat it as a source of truth. Also, don't rely on consistency in clustered mode. - Remember Redis is single threaded so an 8xl isn't going to be super useful with all those unused cores.
Things we have alarms on by default: - Engine utilization - Anomalies in replication lag - Network throughput (relative to throughput of the underlying EC2 instance) - Bytes used for cache - Swap usage (this is the oh shit alarm)
- Only write logs out that matter. Searching logs in cloudwatch is already a major PITA. Half the time I just scan the logs manually because search never returns. Also, the fewer println statements you have the quicker your function will be.
- Lambda is cheap, reporting function metrics to cloudwatch from a lambda is not. Be very careful about using this. - Having metrics from within your lambda is very helpful. We keep track of spout lag (delta of when event got to kineis and when it was read by the lambda), source lag (delta of when the event was emitted and when it was read by the lambda), number of events processed (were any dropped due to validation errors?).
- Avoid using the kinesis auto scaler tool. In theory it's a great idea but in practice we found that scaling a stream with 60+ shards causes issues with api limits. (maybe this is fixed now...)
- Have plenty of disk space on whatever is emitting logs. You don't want to run into the scenario where you can't push logs to kinesis (eg throttling) and they start filling up your disks.
- Keep in mind that you have to balance our emitters, lambda, and your downstream targets. You don't want too few / too many shards. You don't want to have 100 lambda instances hitting a service with 10 events each invocation.
- Lambda deployment tools are still young but find one that works for you. All of them have tradeoffs in how they are configured and how they deploy.
There are some good tidbits in the Q&A section from my re:Invent talk [1]. Also, for anyone wanting to use lambda but not wanting to re-invent checkout Bender [2]. Note I'm the author.
[1] https://www.youtube.com/watch?v=AaRawf9vcZ4 [2] https://github.com/Nextdoor/bender
edit: formatting
- Format all logs in json. This allows you to use the json path filtering option on CW.
- Add function version & tag to the log lines. CW doesn't allow you to filter based on version.
- Don't expect CW log querying to work all the time.
- Output runtime stats to CW metrics.
edit: formatting