1. Talk to the architecture, first talk from what is schema.
The word architecture is used to describe how to achieve some purpose through certain tools, and do not need to be limited to the IT field.
In IT, architecture generally refers to a function of completing the overall software through a specific platform.
The so-called specific platform is more structured into multiple layers.
First, give a first most common 4-storey application. Divided into 1 Express Layer UI2 Functional Layer ACTIVITY3 Data Processing Integrators Data Manipulation4 Data Continuous Layer Data Storage
So, the above four layers of classics are well compliant with the needs of the majority of business models and business software. These include .1 user interfaces (with C / S and B / S) 2 can be frequent, sometimes Very weird client behavior, additional privilege security can also be placed here. 3 In order to make 2 get a transparent database, 34 must be used as a capacity, scale, and security of the program, using different databases or even files system.
I'll talk about the architecture.
1 Architecture determines the software's function. Determine the software's ability. If the company's departments are behind different firewalls, all departments are in different regions, and there are no special MIS departments to support computers. These situations will result in The B / S structure is more convenient than C / S.
2 Users' behavior is very weird, and some departmental supervisors do not need to get higher-level recognition when signing the documents, but there are multiple COPY to other departments that need to communicate with multiple departments and superiors and saved the signature. This time The functional layer is responsible for these boring and cumbersome logic. And please note that these logic will continue to change.
3 In our development perspective, I always want to write some code that doesn't have to change frequently, and some of the programmer comrades don't want to pay attention to boring customer requirements. They say "God, I do you like me." Work, so the data processing integration layer is generated.
4 The most couldn't be determined by my decision is the data continuous layer. For example, our company has a free (because our group bought) Oracle, sometimes they don't want to use more than 100,000 to use SQL. We do programs That's more, give each other a suggestion and choice, such as telling them that "Oracle's maintenance cost is very expensive, we are not very proficient"
Three. Is it true that the architecture is really useful?
Let's first take a look at the necessary sufficient conditions for a program to develop, we must have a demand, there must be resources.
Demand, by the market decision, there is no fixed, large and complicated resources, including human, time two important elements (by way of one, this is the reason for the death of IT comrades)
I will take a few examples to talk about the architecture.
1. We are talking about "II. Why talk to the architecture." When I said a lot of things about users, such as different needs of the managers, and the permissions of each landing personnel. Everyone just gave me a deceived. I told you that "2 Functional Activity Function Layer is responsible for these boring and cumbersome logic." Other. Objective, almost all layers are related to permissions and user logic. People, log in to the same page, you should open to different function buttons. If the department manager, when you see employee information, you should have a button such as the employee, but the employee can't see it. Then this is "1 The function of the performance layer UI "is the function of our" 2 Function Activity "is also done again?
2. I said above "In order to make 2 get a transparent database, I must use 3", I have cheated someone, no database can really transparency, give an example, programmer in "2nd floor" B. If you don't know the structure of the database, how do he communicate with the "3" programmer C, b does not know the database structure, how did he communicate with C? So it is very weird:
First of all, in the development of resources, since the work to be done by the B classmates, A must also understand a part, then why not arrange A and B in one layer, and want them to do their own work. Or You think about the position in B. If you don't make a demand, you can get your interface, it may have been 100 interfaces, only 50 of them are a need, and the other 25 city A is dissatisfied ( For example, if you are not satisfied with the error message), there are 25 that are completely useless. Why should I waste B to do that 25 useless interfaces?
Second, when the demand changes, the more the layers, the more likely the amount of change. Many comrades will say "How is this possible? The hierarchical is for the smallest change." So I said "Possible" Not "ity", why do you say this? If it is the change of the interface, it may be small, or the user's behavior changes, this change may not be big. But you don't think about the problem at a project manager, when a When the change occurs, it must be detained on the various layers of the software. For example, we divide the programmers of 1, 2, 3, 4, and change it to a changed by A, B, C, D changed him to change. What is going to change the corresponding function? B Do you want another different transaction? C as if any change is nothing to do with him but B is saying "I need a new API", c is going to jump up. Because C found that D's database does not have such column. At this time, you will not need to know what D is doing? 3. The speed problem will take a look at our most underlying D classmates, he is responsible for the database. One day My client has been more and more slower to my complaint. I asked A, a said that B is too slow, B is said to be so slow, I will call C, C tells me that he Don't do it, he said, "How much you ask, I am not working on B, I have to deal with B1, B2, B3, etc., the column they want is not big, I will put all the column of the table. Come over. "I have no idea to find D. I will find D. I can make our cute database run. D said a table has 10 million records, C a SEFT Outer Join 6 tables, He asked me "to do INDEX, how do you do?", I said, "I can't stand it, I don't know how to do it."
in conclusion:
1 I said that the architecture is not good, but there is a balance, do not architecture for the architecture. Some complicated requirements can be solved in a very simple method. 2 Even if your customers are good, your customers are God. I am happy with customers. I am happy to get the next day, I can't go to work, I have to go to work for 1 week code. If you really want to write a unlimited unit unlimited unit Large commercial software, which may be more important than architecture than architectures. 3 The traditional backward waterfall development and chaos development model of vintage garbage, and the 2nd floor, or the 3-storey application, sometimes it is more necessary. 4 Many hero always discusses J2EE and .NET to commercial applications. Support, but really use, how much choice do you do? Use it, nor you decide. Is letting the market decide. You are very helpless, isn't it?
me too.
Quote One sentence "You can't do anything you want to do (function), when you can meet 70% of you (customer) hopes, it is very difficult"