Hoshiumi
星海日和
= 代码落在地上,故事落在星海 =
跨越星轨的客
技术 · 生活 · 番剧 · 音乐
Posts
This article systematically introduces the concept, types, storage structure, creation and use methods of database indexes, as well as the optimization principles in practical applications. It is mainly pointed out that although indexes can improve query efficiency, they need to be reasonably designed to avoid overuse; emphasize the column order of composite indexes, the matching of equivalence and range queries, avoid functional processing and NULL operations on index columns, and suggest optimizing based on real query scenarios combined with EXPLAIN analysis execution plans. At the same time, it compares the differences between InnoDB and MyISAM in index organization and transaction support, and points out that InnoDB is more suitable for modern business systems.
This article systematically introduces the basic knowledge and core operations of MySQL databases, covering the differences between relational and non-relational databases, common data types, SQL statement classifications (DDL, DML, DQL, DCL), transaction mechanisms, concurrency control, views, stored procedures and triggers and other key concepts. The content goes from database infrastructure to specific SQL operations, gradually in-depth, emphasizing data integrity, transaction security and performance optimization, and also points out common design principles and precautions in practical applications.
This article introduces the basic composition and development model of Web applications, including front-end, back-end, database and server, and compares the two development models of front-end integration and separation. The front-end integration mode has a high degree of coupling, while the front-end separation mode achieves independent development through interface conventions to reduce dependence. The article also details the responsibilities of Views, Controllers and Models in the MVC hierarchical architecture, as well as the use methods and considerations of core components such as HttpServletRequest, HttpServletResponse, HttpSession, Cookies and ServletContext in the Servlet API, emphasizing issues such as security and thread safety.
This article introduces the basic concepts of the HTTP protocol, request and response structures, common request methods and response status codes, and emphasizes the stateless nature of HTTP and the way to maintain sessions through mechanisms such as cookies. It also explains that HTTPS provides confidentiality, integrity and identity authentication through TLS, and points out that security needs to combine protocol and service-level protection. Finally, specific steps are given for configuring Tomcat to run Web projects in IntelliJ IDEA.
This article introduces the basic concepts of JavaScript, its differences from Java, its core components (ECMAScript, DOM, BOM, events), as well as variables, data types, process control, operators, arrays, functions, and browser operations. It focuses on JavaScript's dynamic typing, common syntax structures, DOM operation methods, timers and page jump functions, and emphasizes the use of let/const in modern JavaScript and the importance of avoiding implicit type conversions.
This article introduces the basic concept of CSS (Cascading Style Sheets), three usage methods (inline, internal, and external style sheets), basic grammatical structure, common selectors (label, ID, class, descendant, grouping, pseudo-class) and core style properties (size, color, font, border, etc.), and demonstrates the application of CSS in button panels and login interfaces through two practical cases. Emphasizes the importance of separating HTML structure from CSS styles, improving the readability and reusability of code.
This article introduces the basic concepts, document structure and common tags of HTML (Hypertext Markup Language). HTML describes the structure and content of a web page through tags, and does not involve programming or compilation. The browser renders the page after parsing it. The article details the usage of common tags such as titles, paragraphs, lists, images, links, tables and forms, and emphasizes that semantic tags and CSS should be used first for style control in modern development. It also points out that older versions of HTML tags and attributes have been gradually abandoned. Finally, a comprehensive case is used to demonstrate the application of HTML in actual pages, and it is recommended that modern projects adopt CSS layout instead of table layout.
This article summarizes the core features of Java 8, including enumerations, basic usage of variable parameters, and the use of interface default and static methods, functional interfaces, Lambda expressions, method references, and Stream streams. Among them, Lambda expressions and Stream streams significantly improve the simplicity and functionality of the code, support functional programming, and can be used for data processing, filtering, mapping, sorting, statistics and other operations, and parallel streams may be processed in inconsistent order.
This article introduces the characteristics and application scenarios of TCP and UDP network protocols: TCP is connection-oriented and reliable transmission, and is suitable for scenarios with high data integrity requirements;UDP has no connection, low overhead, and is suitable for applications that tolerate packet loss. It then explains the programming models of TCP and UDP, including the use of core classes such as InetAddress, Socket, ServerSocket, DatagramSocket, and DatagramPacket, as well as the communication process between client and server. Finally, I mentioned the role of URLs and the use of byte streams and buffers when downloading network files to improve performance.
This article systematically introduces the basic concepts of multithreading, thread life cycle, common operation methods, thread safety and synchronization mechanisms, deadlock avoidance and the use of thread pools. It focuses on the thread creation method (inheriting Thread or implementing Runnable), state transition, synchronization control (synchronized and CAS), thread collaboration (wait/notify), and the core parameters and rejection policies of the thread pool. It emphasizes the importance of thread safety, deadlock prevention and reasonable use of the thread pool. It is recommended to use BlockingQueue and thread pool first to manage concurrent tasks in actual development.