When to develop scalability?

I am about to start a project that I hope will someday need to scale. The key question for me is: should I invest now in developing this opportunity, or should I cross this bridge when I get there?

I know how all this happens: everyone thinks that their project can scale, but most projects never do.

Is there a set of best practices that will allow you to scale more easily at a later stage without investing too much in something you will never need?

Obviously, I have no experience with scalable websites. I am currently leaning towards Scala / Play! / Akka. From what I can get on the Akka website, it is very suitable for such a project (in that it provides a set of tools that allows you to develop on one machine and scale to an arbitrary number of machines).

The project is a consumer-oriented website that includes user interaction (comments, messages, voting, etc.). However, the focus is on editorial work. This is not Facebook :)

Without experiencing any of these technologies (my experience mainly comes from PHP, AS3, Objective-C), I'm probably too much on my record now. But then I'm not going to do it right away. I know that I need to gain experience using Scala and Play! the first.

Any advice is appreciated.

+4
source share
2 answers

Start by simply designing the model, build unit tests for it, and then set the presentation layer on top of it. As long as your model is smart, it will be easy to scale Play to any number of machines. If you go to the JPA support build, you can always decide which database to go for.

At the moment you have more things on your plate. So just make sure your design is consistent and reasonable, then scaling will not be a problem.

+4
source

You have a start using a barren web infrastructure like Play! it will not interfere when you need to scale. As ExxKA says, keep your model clean and reasonable. This will help you maintain the advantage of complexity.

Do not consider this a failure when you need to reorganize your code, or even rewrite important parts of it. This is a natural part of a growing project, like a snake shedding skin.

There are unavoidable things that you will learn in the process of writing a project, so do not try to anticipate them all right now.

+2
source

Source: https://habr.com/ru/post/1396782/


All Articles