Golang app memory requirement

Hello all,

I want to create a blogging app in golang but little confused about memory requirement of golang app, please let me know would i be able to deploy golang app with digital ocean droplet of 4 gb ram, off course this will be initial deployment, after some time i can add more good hardware , but for starting point would this be sufficient?
thanks in advance

I can’t imagine needing more than 4GB to build and run a blogging web server. I wouldn’t be surprised if client-side, you need more than 1GB to run the app in the browser, but server-side, I’d bet you would be fine even with the 512MiB “droplet” for the first hundred or so readers.

2 Likes

Hi @skillian appreciate your quick reply.
i understood that i can deploy golang app in 4 gb droplet (it ia more than enough as you pointed out, only reason i am choosing golang because its compiled, i am very fascinated about compiled languages, for web framework i could find only rust and go as compiled + web supported, long time back i found some memory issues about golang apps memory footprint so i was sceptical about that, i hope golang app can cut the cost in terms of number of requests handled by one droplet.

Hi! Talking about compiled (into binary) languages there are many options outside of Go : Rust, C++, Swift, Kotlin (also java graalvm and C# with mono), Haskell, Nim, etc…a long story. Go has some advantages in backend area so is more popular than others. In terms of memory consumption Go is not bad at all and much depends on the router you choose (which? does it avoid dynamic allocations?) and the framework’s implementation (if you’re using one). Go can be very sober beyond your expectations.
About transfer consumption of course what matters is: reducing json messages size (or whatever you have), compression, external source linked media, browser caching if you need…4GB can be enough for many kinds of app.

1 Like

Hi @Metalymph thanks for suggestions, i had a thought Rust as second option, but go is from google and in India lot of big startup are using golang, I have heard that Rust is the only language after c to be used in linux kernel development which is amazing, other option you listed i will have a thought on that as well.
thanks for your valuable inputs.

1 Like

@MikeJackson thanks for help, i got a brief idea on memory footprint of golang
thanks

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.