a year ago
Hi
I want to deploy a production level backend product for my B2B SaaS on Railway . Currently I’m running this product as a pilot program with 25 Clients, each having 25 daily active users. I had some doubts regarding pricing, features etc. First I like to specify about my requirements below, then according to that please resolve my queries:
Project Details:
Daily requests to be handled by backend per user: 50
Total daily active user: 625
Total Requests daily: 625*50 = 31,250 requests/day
Other Services to be used: MongoDB and Redis
I want to have a private connection between the servers and these services.
The infrastructure needs to be fast.
If required, I want to deploy multiple instances of the servers (horizontal scaling)
Queries:
Based on my requirements, I believe there’s not much heavy traffic coming onto the infrastructure, so based on this, please answer my queries:
What plan should I go for?
Based on my usecase, how much resource consumption can I expect?
(Please give me a rough estimation on how much I’ll be paying for this monthly)
Do I have to pay for both? The plan + Resource usage? (Please give a total pricing estimation for monthly basis)
Note: Since this is a pilot program, I want to have minimum pricing as possible.
Can I scale horizontally by adding multiple instances? If yes, how can I manage the load balancing?
You have not specified the pricing for MongoDB, please include the pricing and also add that in the total monthly estimation you’re calculating.
I want to protect the infra from DDOS and Brute Force attacks, is it possible? If no, then should I do that on application level, I.e, on backend servers manually?
I repeat, please give an estimation for all the components for monthly basis: 1) Server Instances, MongoDB & Redis, Subscription
Please resolve these queries at the earliest, as I have to deploy in next 2 days.
Best Regards,
Saksham
1 Replies
a year ago
Hey there, I'll answer your queries to the best of my ability
> What plan should I go for?
1. Hobby plan is only meant for hobby use-cases and therefore wouldn't work for your setup. Pro plan works best for your needs.
> Based on my usecase, how much resource consumption can I expect?
2. This is near impossible for me to answer, your resource consumption is fully dependent on the applications you run and all the intimate details of the workings of your applications, you'd want to experiment with this yourself. You can use Railway's pricing calculator (bottom of this page) to get an idea.
Sorry for giving such a non-answer but I really can't even give a rough estimate because, for the same application, one person's application could use 50 cents a month while another's uses 4 dollars a month. Maybe because on person's application is written in Rust while the others' is written in Python. Silly example but you get what I mean. The best way to get a good idea would be to run your application somewhere (maybe locally) and check the resource consumption of the application. This should give you the numbers necessary to calculate your rough usage cost.
> Do I have to pay for both? The plan + Resource usage?
3. For pro plan, yes, you play a 20 dollar base-cost (for every person on the team) and then you also pay for usage. If you're the only person who'll be accessing the Railway services then you can expect 20 dollars base-cost plus usage. If you'll have every client on your team then that's 25 * 20 = 500 dollars base cost
> Can I scale horizontally by adding multiple instances? If yes, how can I manage the load balancing?
4. You can scale horizontally very easily and quickly using Railway's built-in replica feature, it uses round-robin load balancing.
> You have not specified the pricing for MongoDB, please include the pricing and also add that in the total monthly estimation you’re calculating.
5. The cost for a MongoDB instance cannot be given because it again depends on you, how much you're connecting to it from a public endpoint, how much you're storing in it, etc. My MongoDB instance costs me around 6 dollars a month with about 100 users worth of data + a ton of data for metrics. I find that typically a near empty MongoDB instance costs around 3 dollars a month and then depending on your usage it can go up from there (check disk costs and egress costs)
> I want to protect the infra from DDOS and Brute Force attacks, is it possible? If no, then should I do that on application level, I.e, on backend servers manually?
6. Railway doesn't provide DDoS protection, you can use Cloudflare for that or as you said use application level solutions
> I repeat, please give an estimation for all the components for monthly basis: 1) Server Instances, MongoDB & Redis, Subscription
7. This is sadly impossible to provide, you'll need to test your total resource consumption yourself and calculate the total based on that, all the information you need to calculate your total cost should be in the pricing page
Hope this helps removing any uncertainties 
Status changed to Solved dev • over 1 year ago
