Posts

Why I Decided to Open Source?

Image
       It all started with a simple realization: some of the best things in my coding journey came from the open-source community. As a budding developer, I often found myself scouring GitHub, marveling at the vast array of projects and the generosity of people who shared their work with the world. It was through this open exchange of ideas and code that I learned, grew, and became the developer I am today. A Sense of Belonging      I remember the first time I contributed to an open-source project. I was nervous, unsure if my code would be good enough, but I went for it anyway. To my surprise, my contribution was welcomed warmly. The feeling of being part of something bigger than myself was exhilarating. This sense of belonging and collaboration was a key reason I decided to open source my projects. I wanted to recreate that welcoming environment for others, providing a platform where they could contribute, learn, and feel valued. The Joy of Learning and Sharing      Open source has al

How to conduct code reviews?

Image
     Based on my experience, having a solid code review plan can make a huge difference in the quality of the software we develop. Over time, I've learned that focusing on different aspects at different stages can really streamline the process and catch potential issues early. Let me break down the approach I use, which has proven to be pretty effective.     API Semantics: The Foundation      I always start with the API Semantics, the foundation of our code review plan. Here, it's all about the big picture—making sure the API is minimal yet sufficient, without any unnecessary duplication. We want it to be intuitive and easy to use, sticking to the principle of least surprise. It’s also crucial to check the cleanliness of the API and ensure any new dependencies come with acceptable licenses. By focusing on these aspects first, we can build a solid base for the rest of the code.   Implementation Semantics: Ensuring Correctness and Efficiency      Next, I dive into Implementation

My experience of using Github Copilot

Image
 It's been a while since I posted anything here. Let's change that! :) The first topic I want to cover is my experience using GitHub Copilot. Let's get started. What is Github Copilot? GitHub Copilot is an AI-powered tool designed to assist developers by providing hints, recommendations, bug fixes, and code writing based on context and guidance. The first version, available to everyone, was released in October 2021. GitHub markets Copilot not just as a "code completion tool" but as an "AI pair programmer." This is a smart move, as it sounds intriguing and generates interest. How to use Github Copilot? Use simple and clear language so that Copilot can better understand your comments and intentions.  Context is crucial for effective interaction with Copilot. Well-structured and readable code, meaningful names for files, classes, methods, and comments all contribute to better results. The more you use Copilot, the better it understands you and the more rele

IMAP protocol summary

Image
IMAP - internet message access protocol. Versions : IMAP1 (Interim Mail Access Protocol) - 1986. IMAP2 (Interactive Mail Access Protocol) - 1988. IMAP3 - 1991. IMAP4 - 1994, last updates - 2003. IMAP is used to read emails that came to the user's mailbox. Emails are stored on server :  Clients connect to the server and download emails only after a user request.  The server can perform complex operations with emails. Advantages : Several clients can work at the same time. All clients see the same mailbox status. Disadvantages :  Protocol is more complex in comparison to POP3. Server space for the mailbox is usually limited. IMAP is an application layer protocol and uses the TCP transport layer protocol. Port 143. IMAP allows you to use multiple mailboxes or folders: Folders are stored on server. Folders can form a hierarchy. Emails can be moved from one folder to another. Flag : It's an email "label". Emails can have one or multiple flags. System flags: \Seen \Answe

POP3 protocol summary

Image
POP - post office protocol. Versions: POP1 - 1984 POP2 - 1985 POP3 - 1988 Updated version of POP3 with additional authentication mechanisms and extensions - 1996 POP3 communication schema The approach "download and delete": The message storage on the server is a temporary storage for messages. All messages must be transferred to the mail client. After uploading to the client, the messages are deleted from the server. Advantages: Simple protocol. Letters are available when there is no network connection. Disadvantages: Only 1 client. Single mail storage (no folders, filters, flags, etc.). POP3 is an application layer protocol (port 110), it uses TCP transport protocol. Session states: Authorization - the client introduces himself and confirms that he is who he says he is. Transaction - the client downloads the mail and marks the downloaded message for deletion. Update - the server deletes the marked message and closes the connection. POP3 works in text mode, interacting in a

SMTP protocol summary

Image
SMTP - simple mail transfer protocol. Created in 1982 with further modernization in 2008 (ESMTP). A protocol is used for mail transmission and can work with any transport protocol (TCP, UDP). General mail exchange idea Ports : 25 - mail transmission between servers (mail transfer agent) 587 - mail transmission from client On practice port 25 is used.   Email format :   Envelope (SMTP commands)           Header (RFC 2822)         Body (RFC 2822) SMTP works in text format (request - response interaction). Commands : SMTP responses:   Letter headers: Extended SMTP (ESMTP) commands: EHLO - extended HELO STARTTLS - to use encryption SIZE - max allowed letter size DSN - letter delivery confirmation Security and spam: SMTP does not contain data protection mechanisms. The contents of MAIL FROM and FROM are not controlled in any way Data is transmitted over the network in open form (except using STARTTLS) Spam defence: Checking the sender's domain via DNS Mail servers only accept emails f

System design tips on how to make capacity estimation

Image
Estimation is an important skill in system design interviews because it allows you to demonstrate your ability to reason about the complexity and feasibility of a given problem. It is worth noting that estimation is an inexact science and that it is normal for estimates to be off by some margin. It is more important to show that you have a clear understanding of the problem and can provide a thoughtful and well-reasoned estimate than to provide a perfectly accurate one. Here are a few examples of the types of estimation questions you might encounter in a system design interview: How many users can a system support? For example, you might be asked to estimate the number of users that a social media platform can support, based on the number of servers, storage, and bandwidth available. How much data can a system store or process? For example, you might be asked to estimate the amount of data that a data warehouse can store, based on the size of the data, the number of serv