Emphasis on "one per partition", which if I understand correctly as "network partition", means that in the absence of network partition, there is one leader.
I do have only a surface understanding of Raft, and I'm learning while doing yes.
In Raft state space is split into partitions. Each partition gets it leader. For example in a cluster of 3 nodes and 65536 partitions each node is a leader for 1/3 of partitions with two others acting as replicas. This way each node simultaneously leader for some partitions and replica for others.
I'd add though, that the "one leader" thing was not the only reason why I ditched Raft. The Go library hashicorp/raft was quite complex to use, and I've had a lot of situations where the cluster failed to elect a leader, and ending up with a corrupted state.
It's a log management/processing software, with visual scripting.
Started out of frustration towards OpenObserve and its inability (at the time) to properly/easily refine/categorize logs: we had many VMs, with many Docker containers, with some containers running multiple processes. Parsing the logs and routing them to different storages was crucial to ease debugging/monitoring.
It was initially built in Go + HTMX + React Flow encapsulated in a WebComponent, I then migrated to React (no SSR). It integrates VRL using Rust+CGO.
It is by far easier to use than Logstash and similar tools, and in fact it aims to replace it.
I do work and target Windows for a few other projects.
Also, not trying to start a flamewar, but I've spent too much time tinkering on Linux in the past. There is *always* some hardware compatibility issue, or some missing drivers, and especially with GPUs. Linux works best on a server, or on a VM. At least, that is my experience (and I've been on Linux for more than a decade, be it with either Debian, Archlinux, Gentoo, or Ubuntu).
you're not trying to start a flamewar but you're spreading inaccurate info... fyi, at our company, all pc 12" to 43" dell latitude optiplex or nuc intel or custom are on ubuntu or now debian/xfce... management, sales, infographics, software development, hardware design...
The ability to autocomplete, and navigate through the code (even my dependencies's code) by the click on a function, the popover showing the documentation/signature of the function i'm going to call. Those are Quality of Life features I'm not ready to give up on.
As said in a sibling comment, I often work on cross-language projects, I don't recall Jetbrains offering a "one size fits all" IDE.
> The ability to autocomplete, and navigate through the code (even my dependencies's code) by the click on a function, the popover showing the documentation/signature of the function i'm going to call. Those are Quality of Life features I'm not ready to give up on.
ctags did most of that decades ago. Plain vim has good autocomplete and signature popovers, along with navigating to functions and class definitions. No LSP needed. An LSP will do it better but with sometimes significant overhead.
As I noted I don't use VSCode or a JetBrains IDE. I know about them and have used them. My setup works language-agnostic, and I also work in multiple languages.
I don't have a lot of extensions actually, my VS Code is pretty much vanilla.
I'm on the latest version (1.97.2).
I can try the other memory settings indeed, but I think the culprit is the builtin file watcher. I've stumbled across some similar issues on Github, open for 5 years without a solution :(
Isn't IntelliJ IDEA for Java/Kotlin? I have a project which is cross-languages: Go+Rust on the backend, Typescript/React on the frontend, Hurl and Python (Robot Framework) for the test suite. And I'd rather not have one IDE per language (which is IIRC what Jetbrains do).
The underlying spirit of marshughes comment sounds on the right track, though - something changed on your system. Maybe it was VS Code, maybe it was something else, but if this is a recent change, you should troubleshoot what actually changed. If it really is VS code, then yes - find a new editor. But I'm not seeing much about what troubleshooting you've done?
Maybe you've already done this, but if I were you, I'd take note of everything that has been installed and updated in the last month. Walk back installs and updates until your problem goes away, and then you'd know exactly what is causing the problem behavior.
To me the implication is that the culture at this company won't allow this team to master Go either, and in a few years there will be a post describing how they moved from Go to another language.
Many people like to write about how Golang is so simple, but the drawback of that simplicity is that many features of other languages are either covered by additional dependencies or by inflating code size. It's just as possible for Go projects to devolve into big balls of mud as for any other language.
The mindset that you can master any programming language in a month is exactly what I meant in my previous post. There's a veritable cottage industry of "golang pitfalls" blog posts out there that show there are absolutely a lot of footguns in Go.
For example, what do you think the following should print?
values := []int{4, 8, 15, 16, 23, 42}
for value := range values {
fmt.Println(value)
}
I don't think there are very many people who would guess the integers 0 to 5.
I also like the following one:
ch := make(chan int)
ch <- 1
fmt.Println(<-ch)
What would this print? The only correct answer is sadly "fatal error: all goroutines are asleep - deadlock!".
Golang is a fine language and simpler than most, but sadly "simpler" is not the same as "simple".
But people here are comparing a language standard library with a framework like Spring, which doesn't make sense.
The Java standard library has a web server in it, it has JDBC. You could use those directly. That's comparable to the Go standard library. For real apps people don't do this because they want a lot more, like simplified database access or session management.
It strongly resembles JDBC. Doing a database query with that is verbose and error prone. Compare the work needed to do a lookup query and map the results to a data structure with that to (Micronaut syntax, Spring is similar):
var someGopher = gophersRepository.findById("goo");
Add the username/password/host/port to the config file and that's all you need for db access. Compare to the Go stdlib which wants you to manage drivers, connections, prepared statements, rollbacks, etc. It's a different level of abstraction.
There are a lot of leanings to master for Go as well which they may have not discovered.
As an example, the Go runtime does not honor container resource limits. You would think this would be one of the very first fundamental features supported out of the box by an advertised "cloud native" language.
Go 1.19 only had this in its notes for memory changes
"...includes support for a soft memory limit. This memory limit includes the Go heap and all other memory managed by the runtime, and excludes external memory sources such as mappings of the binary itself, memory managed in other languages, and memory held by the operating system on behalf of the Go program"
> ...includes support for a soft memory limit. This memory limit includes the Go heap and all other memory managed by the runtime, and excludes external memory sources such as mappings of the binary itself, memory managed in other languages, and memory held by the operating system on behalf of the Go program"
Of course it’s a runtime setting, it won’t affect other factors but you can’t say it didn’t solved anything “because there’s a GitHub issue open” Then Go runtime was unpredictable because of its ideology “CPU is unlimited but not Memory” and containers are kinda of a dynamic resource allocated but it did solve vast amount of problem dealing with kernel OOM and unpredictable GC cycles
I would be surprised if the Go team implemented it into the runtime, because some devs would love to have there own way of handling such settings so I don’t see it as an issue
We can’t just compare added features if don’t compare how backwards compatible the language is at that time I don’t know much about Java, but I wouldn’t say the same from upgrading from Go 1.9 to Go 1.19
Sorry, but no - putting the burden on the developer to detect whether they are running in a container or not and then determine and adjust to cgroup settings is far too high an encumbrance on the service developer. This is a demonstrative example of a fundamental responsibility that should always be delegated to the runtime as the default behavior.
Neither Go 1.19 nor any subsequent version has "solved" this issue.
> Sorry, but no - putting the burden on the developer to detect whether they are running in a container or not and then determine and adjust to cgroup settings is far too high an encumbrance on the service developer.
Because there’s no one way solution to this problem, the problem isn’t unique to only Go, but every GC language because you’re starving the program if there isn’t sufficient CPU Quota it will all eventually lead to CPU throttling, this isn’t really the problem of Go or any other GC language but at the OS layer, the inherent nature of containers
Secondly am pretty sure the Linux CFS does not strictly follow the CPU Quota, tho there could be something like a panic or warning, or switching to entirely different memory management just for what ? people who want 10ms ?
I do have only a surface understanding of Raft, and I'm learning while doing yes.