Jeff Yan's discussion about different software architectures and software frameworks

Source: Internet
Author: User

The following is a speech by Dr. Yan Hong in a csdn discussion on Architecture and Framework concepts. It is very helpful for us to understand these two concepts!

"
Architecture: Architecture
Framework: Framework

The large-scale architecture of software is architecture. A software may have an architecture, regardless of its quality. The framework can be used or not used in the software architecture. For example, JSP is a framework, and your system can use the JSP framework to form its own architecture.

All frameworks are designed according to Hollywood principles, otherwise they are not called frameworks. The so-called Hollywood principle refers to you don't call us-we will call you. It means that the code under a framework is passively called by the framework, rather than the opposite. In this way, a large number of repeated code can be hidden in the framework. Code that requires special design should be handed over to the developers in the way of a predetermined interface. After the code is written, it will be called by the framework.

For example, JSP is a framework. The JSP script you write will be compiled into a part of the servlet by the JSP Engine. This type of servlet carries a large number of repeated code, which is not required by JSP programmers and is the responsibility of the framework.

"

"
If the house is used as a metaphor, the architecture is an abstract building structure that ignores the details. It can be seen in the drawings that exist in the human brain and does not represent a physical part of the house. Architects are architects. Architects are architects in English.

Software Architect: Software Architect ect
Architect: Building architect ect

The framework is the skeleton of a house, and the skeleton of a house exists physically.

Karl. Marx said in the capital theory that the bee-built beehive could outshine the most outstanding building of mankind, but the worst architect is better than the bee, because before the designer starts designing, the architecture of the house already exists in the minds of designers.

Marx means that human design is purposeful activities, and bees are not. What Marx said exists in the human brain, and the architecture is not a framework. If the frame of a house falls into the human brain, even if it is a small part, the person will die.
"

"
The following is an excerpt from my book, which has never been completed.

Section 1.1 What is architecture
What is the architecture of a software system )? Generally, the architecture has two elements:
& #61548; it is the highest level of division of a software system from the whole to the part.
A system is usually composed of components, and how these components form and interact with each other is an important information about the structure of the system.
Specifically, it includes architecture components, connectors, and task-flow ). The so-called architecture element is the core "brick" of the system, and the connector describes the path of communication between these components, the mechanism of communication, and the expected results of communication, the task flow describes how the system uses these components and connectors to fulfill a requirement.
& #61548; decisions on the highest levels of business and technology made by building a system that will not be changed in the future.
There are many important decisions that need to be made prior to building a system. Once the system starts to be designed or built in detail, these decisions are hard to change or even unable to be changed. Obviously, such a decision must be the most important decision on the success or failure of system design and must be carefully studied and investigated.

The history of Computer Software began in 1950s, and its history was very short. In contrast, construction engineering started from the Stone Age, and humans have accumulated a lot of experience and lessons in architectural design practices for thousands of years. Architectural Design basically includes two points: first, architectural style, but architectural model. The unique architectural style and the appropriate architectural model can be unique.
The pictures below show the ancient Maya buildings in Central America, the Great Pyramid of chichei-Itza, and nine huge stone-level heaps. the hundreds of millions of steps lead the way out, and the temple on the top of the tower is on the sky. All numbers are strictly prohibited like calendars, and the style is vigorous. It is hard to imagine that this is a stone-age building.
 
Figure 1.1: ancient Maya civilization building in chichei-Itza, Mexico. (Photography: min Hong)
The relationship between software and human beings is the core issue that architects must face. It is also a problem that has occurred since the software entered the stage of history. Like this, the relationship between architecture and human beings has been the core issue that architects must face since building. British Prime Minister Churchill said that we constructed a building and then constructed us (we shape our buildings, and afterwards our buildings shape us ). The conference hall in the lower House of Commons is narrow, so that all members of the lower House of Commons cannot be seated in the same direction, but must be divided into two sides. Churchill believes that Members of Parliament will naturally choose to sit at the same time as their political views. The key to the origins of British political parties is the influence of buildings on people.
In the software design field, many people think that the function is the most important, and the form must obey the function. Like this, Louis Sullivan, one of the creators of modern architecture schools in the architectural field, also believes that the form should be subject to the function (Forms follows function ).
Almost all software design concepts can find more distant historical echoes in the vast history of architecture. The most famous, of course, is the model theory and XP theory.
What is the goal of the architecture?
Just as the software has its own goals, what are the goals of architecture design? In general, the software architecture design should achieve the following goals:
& #61548; Reliability ). Software systems are extremely important for users' business operations and management. Therefore, software systems must be very reliable.
& #61548; security line (secure ). The business value of the transactions undertaken by the software system is extremely high, and the security of the system is very important.
& #61548; scalable ). The software must be able to maintain reasonable performance when the user's usage and number of users increase rapidly. Only in this way can we adapt to the possibility of expanding the user's market.
& #61548; customizable ). The same set of software can be adjusted based on different customer groups and changes in market demands.
& #61548; extensible ). When the emergence of new technologies, a software system should allow the import of new technologies to expand the functions and performance of existing systems.
& #61548; maintainable ). Maintenance of software systems includes two aspects: first, to eliminate existing errors, and second, to reflect new software requirements to existing systems. An easy-to-maintain system can effectively reduce the cost of technical support
& #61548; Customer Experience ). Software systems must be easy to use.
& #61548; time to market ). Software Users must face intra-industry competition, and software providers must also face intra-industry competition. It is very important to compete for market opportunities as quickly as possible.
Architecture type
Based on our concerns, we can divide the architecture into three types:
& #61548; relationship between logical architecture and components in software systems, such as user interfaces, databases, external system interfaces, and commercial logic components.
For example, the following figure shows the logical architecture of a software system that I have personally experienced.
 
Figure 1.2 shows an example of a logical architecture.

From the figure above, we can see that the system is divided into three logical layers: appearance level, business level and data persistence level. Each layer contains multiple logical components. For example, the web server layer includes HTML service components, session service components, security service components, and system management components.
& #61548; how physical architecture and software components are placed on hardware.
For example, the following physical architecture diagram describes the physical architecture of a distributed system distributed in Beijing and Shanghai. All the components in the diagram are physical devices, including Network Shunt, proxy server, web server, application server, Report Server, consolidation server, storage server, host, and so on.
 
Figure 1.3 shows an example of a physical architecture.

& #61548; system architecture and non-functional features of the system, such as scalability, reliability, robustness, flexibility, and performance.
The design of the system architecture requires the architect to have excellent knowledge of the functions and performance of software and hardware, which is undoubtedly the most difficult task in architecture design.
In addition, from each perspective, we can see two elements of the Architecture: component division and design decision.
First, components in a software system are logical components first. How these logical components are put on the hardware, and how they contribute to the scalability, reliability, robustness, flexibility, and performance of the entire system are very important information.
Second, the decisions that need to be made for software design will inevitably include the logical structure, physical structure, and how they affect all the non-functional features of the system. Many of these decisions are hard to be changed once made.
Based on the author's experience, a database-based system architecture, how many data tables will be there on how many pages of architecture design documents. For example, a medium database application system usually contains about one hundred data tables. Such a system design usually requires about one hundred pages of architecture design documents.
Architect
Software designers who have high technical skills and rich experience need to design the architecture of the software system, that is to say, we need to design how the system's components are divided, how components interact, and how logical, physical, and important decisions are made in the system.
Such a person is called an architect ). In many companies, architects are not specialized and formal roles. Generally, the most experienced programmer in a Development Group is responsible for some architectural work. The most experienced project manager in a department is responsible for some architecture work.
However, more and more companies recognize the importance of architecture work and set specialized architect positions at different organizational levels, they are responsible for the design, configuration, and maintenance of logical architecture, physical architecture, and system architecture at different levels.
"

"
MVC is an architecture model .. Net is a development platform.

A software system can use multiple frameworks at the same time.

It is impossible to use a framework for every line of code.

There are a lot of people who can develop software without understanding software engineering, so far I will only say good luck to such a friend. You can do whatever you want.

If you take software engineering seriously, you 'd better use the concept of pass. The concept is intended for communication purposes. If you use a defined concept, there will be no other results except for the confusion of communication.

Library or class library is not a framework, although the framework can be reflected as a library or class library. Hollywood principles are characteristic of all frameworks, not just in good frameworks.

If you want to create a product, it is good, but not when using terms and concepts. The term and concept require the cloud.

For example, there is a restaurant in Beijing that prohibits Japanese people from entering the house. There is a brand outside, and a line of English is written (why is it not Japanese? I don't know). It says "Japanese forbid entering ". It seems that the Japanese prohibit others from entering the website. To learn a language, you must understand the language. Otherwise, the Americans cannot understand your English. Can you create a language in English? Let's talk about creation first.

Learning any science or technology involves the adoption of common terms. Just as English is used for communication, these terms and definitions must be mastered first. If you want to create one, you must first pass this step. In turn, give up the concepts of these terms and create one by yourself. The only effect is that it seems to be in English, but it cannot be understood in English. It seems to be in software engineering, discuss playing the piano in the way of software engineering.

If you encounter such a problem, you are not faced with the problem of being able to create it, but with no entry. The Japanese are Japanese, the forbidden is forbid, and the inner is entering. Therefore, if the inner is Japanese, the inner is Japanese forbid entering. There are many imaginary opinions in the discussion, which are actually childish manifestations. Unless he does nothing, what he does is something like Japanese forbid entering.

"

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.