English Article · Software

Good Code (in short)

Good code is following 3 main concepts:

  • Readability – code is generally clean, others understand your code.
  • Scalability – can the code perform good with small amount of elements compared to big amount of elements? Can the code be easily scaled horizontally? In general it covers different areas, from algorithm prospective where developer should care about Big O notation to high level architectural things.
  • Evolutionary architecture – code must be easy changeable/evolving over new requirements.

Main concepts for readability:

  1. Use Single Responsibility Principle – the part of SOLID principles, which already describes good technics.
  2. Check for Code Smells”, is your methods simple enough, the name understandable for other developers?

Main concepts for scalability:

  1. Server should able to work with high usage and handle a lot of concurrent connections.
  2. High performance over time. What if your solution works speedy on low amount of data, but getting slower in some time when database become heavy? CRUD operations must rely on good DB architecture.’
  3. Solution must be easily scaled horizontally and in the one way use Kubernetes as a helper for complex apps.
  4. Load Balancer as a must.
  5. Decouple cache from application.
  6. Consider to use not only relational DB, but also No-SQL.

The topic will have updates over time.

One thought on “Good Code (in short)

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.