Posts

Showing posts from July, 2024

ORM - Hibernate

ORM - Hibernate Developed in 2001 by Gavin King, Hibernate was introduced as a groundbreaking alternative to the EJB2-style entity bean approach. Hibernate is java based ORM tool that provides framework for mapping application domain objects to the relational database tables and vice versa, also provides data query and recovery facilities. By mapping Java objects to database tables, it streamlines data persistence and retrieval without the need for complex SQL queries. Features: Automatic Transaction Management and Caching What is JPA? Java Persistence API (JPA) is a Java specification that provides specific functionality and is a standard for ORM tools. javax.persistence package contains the JPA classes and interfaces. Hibernate is an implementation of JPA guidelines. Hibernate is described in org.hibernate package. Hibernate is an Object-Relational Mapping (ORM) tool that is used to save the Java objects in the relational database system. Hibernate Lifecycle Transient State - When in...

ExpressJS

 ExpressJS

kotlin

 kotlin

System Design Basics

  System Design Basics Load Balancing Algorithms In cloud computing, distributed systems, and network architectures, load balancing ensure optimal performance, reliability, and scalability. load balancing handling web traffic, distributing computational tasks, or managing resource utilization directly impacts the efficiency and stability of the entire system. 8 Load Balancing Algorithms for System Design : 1) Round Robin The Round Robin algorithm operates on a cyclic basis, evenly distributing incoming requests across a pool of servers. It sequentially assigns requests starting from the first server and loops back once reaching the last, ensuring a fair distribution of workload. Round Robin algorithms works best when have a homogeneous server environment with similar hardware and the requests are generally uniform in complexity and resource requirements. 2) Least Connections 3) Weighted Round Robin 4) Weighted Least Connections 5) IP Hash 6) Least Response Time 7) Random 8) Least B...

RabbitMQ

What is RabbitMQ? RabbitMQ is an open-source message broker for reliable, scalable communication between applications. RabbitMQ is an implementation of the AMQP message model (Advanced Message Queueing Protocol) Version 091. RabbitMQ is an open-source message broker that enables reliable, scalable, and asynchronous communication between distributed applications. Advantages of RabbitMQ: Background Processing:  - Ideal for handling long-running tasks such as processing uploads on web servers, where users can continue with additional tasks while processing occurs in the background. Control:  - Developers can define how messages move through the system using message metadata, rather than relying solely on broker administrators. Cross-Language Communication:  - Messages produced in one language can be consumed by applications in different languages, enhancing versatility. Message Acknowledgements:  - Ensures message delivery by keeping messages in the queue until receipt ...

PostgreSQL

What is ⁠PostgreSQL? PostgreSQL is a robust, open-source object-relational database system known for advanced features, scalability, and support for complex queries. PostgreSQL is one of the most trusted names in open-source relational databases. Its development started back in 1986 at UC Berkeley under Michael Stonebraker. PostgreSQL is technically an object-relational database. PostgreSQL is one of the most trusted names in open-source relational databases.  Its development started back in 1986 at UC Berkeley under Michael Stonebraker. Why PostgreSQL is Best? Key Features: User-defined Types:  - Customize your own data types.  - Object-Relational Database Management System (ORDBMS) Table Inheritance:  - Use table inheritance for better data management. Sophisticated Locking Mechanism:  - Ensures data consistency. Foreign Key Referential Integrity:  - Maintains database integrity. Views, Rules, Subquery:  - Powerful query capabilities. Nested Transact...