Wuzhiyong's Backend Development Guides

website·Indexed 30 days ago

https://blog.wuzhiyong.eu.org

A collection of technical tutorials and notes focusing on Java backend development. Content includes Java core syntax, OOP, multithreading, and the Collection Framework, as well as detailed guides on distributed systems and infrastructure including Kubernetes, Kafka, Elasticsearch, Zookeeper, Nginx, and Spring Cloud. Additionally, it features a comprehensive series on software design patterns such as Singleton, Observer, Strategy, and Factory.

Tokens
611K
Snippets
3.1K
Records
3.8K
Agent score
49%

What's inside Wuzhiyong Blog

  1. Overview of Java Swing GUI Framework

    Swing is a part of the Java Foundation Classes (JFC) used to build graphical user interfaces (GUIs). It is written entirely in Java, making it more platform-independent than AWT. All Swing components are located in the javax.swing.* package and their class names typically start with 'J' (e.g., JFrame, JButton).
  2. Overview of Java Collection Framework structures

    The Java Collection Framework (located in the java.util package) is divided into two primary structures: the Collection structure (elements stored individually) and the Map structure (elements stored as key-value pairs). Collections store references to objects in the heap, not the objects themselves. By default, without generics, collections store any object that is a subclass of Object.
  3. Overview of Google Protocol Buffers (Protobuf)

    Google Protocol Buffers (Protobuf) is an open-source, lightweight, and efficient structured data storage format used for serialization. It is particularly suitable for data storage and Remote Procedure Call (RPC) data exchange. Unlike standard Java serialization, Protobuf is cross-platform and cross-language (supporting C++, C#, Java, Python, etc.), offering higher performance and smaller binary sizes.
  4. Overview of React Hooks

    Introduced in React 16.8, Hooks allow developers to use state and other React features within function components without writing a class. Hooks are functions that 'hook into' external React functionality. They solve several problems associated with class components:

    1. Logic Reuse: They allow stateful logic to be extracted and reused across components without changing the component hierarchy.
    2. Complexity: They allow related logic (e.g., data fetching) to be grouped together in smaller functions rather than being split across lifecycle methods.
    3. Class Overhead: They eliminate the need to understand the complexities of this in JavaScript and the need to bind event handlers.
  5. Overview of MyBatis-Plus

    MyBatis-Plus (MP) is an enhancement toolkit for MyBatis. It is designed to simplify development and increase productivity by providing additional functionality without altering the core MyBatis framework.
  6. Overview of Java Annotations

    Annotations were introduced in JDK 1.5. They are used to embed supplementary information into the code (on classes, properties, methods, etc.) without changing the actual logic. Unlike comments, which are ignored by the compiler, annotations are read by the compiler or other programs to determine different processing behaviors. In modern Java frameworks, annotations are a core component alongside reflection and design patterns.
  7. Introduction to JSP Expression Language (EL)

    Expression Language (EL) is a part of JSP syntax designed to replace Java code (scriptlets like <% %> and expressions like <%= %>) within JSP files. Its primary purpose is to retrieve data from a specific scope, convert it to a string (automatically calling toString() for Java objects), and output it to the browser, resulting in cleaner and more maintainable JSP files.
  8. Overview of Java Reflection mechanism

    The Java Reflection mechanism is a set of JDK libraries used to operate on or read class bytecode files at runtime. The core classes involved are:

    • java.lang.Class: Represents a class file on disk or a specific type.
    • java.lang.reflect.Field: Represents a member variable within a class.
    • java.lang.reflect.Method: Represents a method within a class.
    • java.lang.reflect.Constructor: Represents a constructor within a class.
  9. Overview of Apache ZooKeeper

    ZooKeeper is an open-source, high-performance distributed coordination service designed to provide consistency for distributed applications. It is a coordination storage service with strict attribute access control, often used as a critical component in Hadoop and HBase. Its primary design goals are:

    1. High Performance: Stores all data in memory and serves non-transactional read requests directly, making it ideal for read-heavy workloads.
    2. High Availability: Operates in clusters (typically 3-5 machines). As long as a majority of the nodes are functioning, the cluster remains available.
    3. Strict Ordering: Every update request is assigned a globally unique, incrementing sequence number (zxid) to reflect the order of operations.
  10. Overview of CommonJS Module Specification

    CommonJS is the module specification used by Node.js. It defines a standard for structuring code into reusable modules. In CommonJS, every file is treated as a module. On the server side, modules are loaded synchronously at runtime. For browser use, CommonJS modules must be pre-compiled or bundled because browsers do not natively recognize the require syntax and synchronous loading would block the UI thread.
  11. Overview of RTK Query for data fetching and caching

    RTK Query is an optional plugin included in the Redux Toolkit package designed to simplify data fetching and caching in Web applications. It eliminates the need to manually write logic for loading states, caching, and deduplicating requests. It is specifically designed for React (requiring version 17+ with Hooks support).

    Key problems solved by RTK Query:

    1. Managing UI based on loading states.
    2. Reducing duplicate requests for the same data.
    3. Implementing optimistic updates for better UX.
    4. Managing the lifecycle of cached data during user interaction.
  12. Overview of the Netty Framework

    Netty is an asynchronous, event-driven Java open-source network application framework designed to facilitate the rapid development of high-performance, high-reliability network IO programs. It is essentially an NIO framework optimized for high-concurrency applications using the TCP protocol or large-scale continuous data transmission in Peer-to-Peer (P2P) scenarios.