Answer the question
In order to leave comments, you need to log in
Frameworks, extensions, a sea of technologies… what are they for?
Guys, please explain this thing. Maybe I just don't understand something. I am reading an article : to work with MVC4, it is recommended to take Entity Framework 4.1 (Code First), MvcScaffolding, Ninject, NLog ... a bunch of packages and libraries, without which life is uncomfortable.
The main question that torments me constantly - why all this ? Why do we need dozens of libraries, plugins, new frameworks? Okay, let's say Code First makes the development of the application easier. But at what cost? There were posts about the fact that hardware is improving, but programs continue to slow down - is it because of this? Dozens of layers, abstractions eating away their resources. MvcScaffolding - code generation, such as CRUD panels. Again - is it really impossible to do without simple methods?
Maybe I'm a bad developer, poking around on my lawn for the last 5 years and feeling like I'm wildly, incredibly wildly behind all the newfangled technologies and trends. I'm trying to figure out what it's for and I just don't get it. I start picking EF and I understand that how well I lived without it before, I will continue to live, life will not be much easier. MVC - cool, fancy, universal - but loses compared to the same PHP in many ways. A simple MVC project is about a dozen folders, five configs, a bunch of controllers. Again - where such difficulties? For what?
The threshold for entering all this seems to be low, yes, but in order to maintain your own level, you have to jump through the basics of a bunch of technologies, while not understanding a single one to the root. I have mad respect for the people who here in the comments or in the posts paint the insides of .Net technologies, but ... when do you have time to figure it out? How many years of tinkering does it take to know for sure that calling this will lead to this , calling that does that , and five layers of abstraction deep, and the feature of that one gives an advantage in this. And how can you delve into the technology in order to put it into practice, if in a couple of years a newer technology appears or the old one changes radically and you need to rummage again, study it again, etc.
How to remain a normal programmer not in the backyard, not to lose your grip and not get lost in all this?
PS cry of the soul, I'm sorry if I offended someone.
Answer the question
In order to leave comments, you need to log in
> why all this?
If you don't need it, don't use it. I usually get along just fine without all of that, with the exception of NLog. to do the right logging is another task.
> Again - is it really impossible to do without this simple methods?
You don't disclose what simple methods are for you. If this is WebForms with all the logic in the code-behind, then what are the volumes of projects and how many people are working on them? When you get lost in the code noodles, you will find that another MVP pattern is recommended for WebForms .
> A simple MVC project is about a dozen folders, five configs, a bunch of controllers
Not true. I open the solution: about 15k LOC (this is not much, but not HelloWorld), in the web project there are only standard folders: Controllers, Views, Models. A bunch of controllers usually contains a tiny amount of code, compared to the lower layers.
> MVC - cool, fancy, universal - but loses in comparison with the same PHP on many points.
You compare oranges with apples, MVC is a pattern, PHP is a language. And on Dotnet, you can also write in the Response.Write style, and there are dozens of MVC frameworks for PHP.
If the MVC pattern is not suitable for your task, well, there are plenty of others. If the number of controllers bothers you, there is a kind of MVC - Front Controller , and even an implementation for dotnet: FubuMVC ,
> And how can you delve into the technology in order to put it into practice, if in a couple of years a newer technology appears or the old one changes radically
Read Fowler, all these abstractions are standard and almost the same everywhere.
> Frameworks, extensions, a sea of technologies… what are they for?
Different problems have different solutions. To have a choice.
> How to remain a normal programmer not in the backyard, not to lose his grip and not get lost in all this?
Pull up the materiel: start with Fowler , add Martin to taste . Decide for yourself what suits you and what doesn't.
In conclusion, I want to say that the light did not converge on MVC. There are many alternative patterns and their implementations for dotnet: Nancy, OpenRasta, FubuMVC, Manos, ServiceStack…
If you are writing a large application that is made by several people and needs to be maintained, then frameworks save a lot of time. Of course, not for free, but at the cost of worse performance (i.e. you need more serious hardware). I am not an expert in PHP, I can say about Java. The functionality that Spring, Hibernate, GWT will give me - I myself would have been writing for years.
Of course, in each specific case, it is necessary to decide whether a framework is needed, and if so, which one ...
How many years of tinkering does it take to know for sure that calling this will lead to this
> There were posts about the fact that iron is improving, and programs continue to slow down - is it because of this?
> Dozens of layers, abstractions eating away their resources.
Look at the talks of architecture highoad projects. Three things can slow you down - disk operations, database and network. OOP certainly loses in speed of execution to the procedural approach, but this loss is 0.00001% of the query to the database. If the program slows down, then not because of the layers of abstraction, but the above reasons.
> MVC - cool, fancy, universal - but loses compared to the same PHP in many ways.
There is either an inaccuracy in the wording or a misunderstanding of the difference. You cannot compare MVC and PHP, the first is a design pattern, and the second is a programming language. PHP has a bunch of frameworks that adhere to MVC.
> A simple MVC project is about a dozen folders, five configs, a bunch of controllers. Again - where such difficulties?
> For what?
This greatly simplifies life even in small projects, in large projects the benefits of this grow exponentially.
>when do you get it right? How many years of tinkering does it take to know thoroughly that calling this
> this will lead to this, calling that does that, and five layers of abstraction in depth, and the
> that feature gives an advantage in this.
It depends on the experience and complexity of the platform, an experienced programmer (5 years of full-time commercial development) will need from a couple of days to a couple of weeks to start a new project on an unfamiliar framework, 3 months to feel confident and 1-2 years to thoroughly understand in all entrails.
Judging by the year of birth, you are just starting your way in programming. So if you still can't figure something out, that's fine. With experience comes understanding.
> And how can you delve into the technology in order to put it into practice, if in a couple of years there appears
> a newer technology or the old one changes radically and you have to rummage again, study again, etc.
New technologies fundamentally different from all previous ones appear rarely, if at all. All new technologies are based on previous experience. For example, the newfangled MongoDB, which is yet to become mainstream, is based on JavaScript and JSON, and these technologies are familiar to any web developer. Another example of newfangled NoSQL technologies is key-storage storages such as memcached and redis, anyone who has worked with relational databases will understand them in 5 minutes. Of course, it takes more time to get into the intricacies of the API and configuration, but there is nothing complicated there.
Don't sweat it. IMHO, in the modern world there really is a tendency to use libraries, frameworks, patterns in cases where you can safely do without them, and when they do more harm than good.
This of course does not mean that all these MVCs are not needed. They are needed - this has already been described in other answers here. Just by studying them and the existing code, keep in mind that if you think that this library does not belong here, it probably is.
In a global sense, this is the problem of our economy. What you described is just a special case: the projection of our consumer economy onto the IT level. We can observe a similar problem in all spheres of life: disposable things are produced in order to get more momentary profit. This applies to software, and devices, and clothing (there is a concept of fashion here), and household items ...
It is clear that it is not at all necessary to release a new version of Windows every 3 years. There is only one meaning in this - the manufacturer wants to make a profit from new sales.
On the other hand, the users themselves are hooked on this "needle" - they are already tired of the program, they want a new version. In addition, changing one program (operating system or framework version) entails the need to change all other programs. Extra work from scratch ...
The same trouble with frameworks. A lot of money is invested in the promotion of the framework. Then the customer wants his project to be completed on one or another framework, because. he had already been convinced of his "coolness".
Further, along the chain, the ability to use one or another framework makes some programmers competitive, others not competitive. Again, the programmer is forced to "upgrade his brain" in order to receive money. The meaning is financial.
Of course, in the global sense, the “disposable economy” only harms humanity. One-day technologies lead to the fact that people do not have time to study anything deeply - they just figured out ASP.Net WebForms, they already need to learn MVC and so on.
Next, game theory applies here. Although all mankind loses from one-day technologies, on a personal level it brings profit (selfish interest).
Frameworks are essential as the basis of any more or less complex project.
The main reasons:
-Standardization and maintainability of the code, and this, almost always, is more important than a few percent of the overhead.
- Simplification of collective development.
-Code reuse - no need to implement typical things every time and debug extra code. This also applies to libraries. Writing everything from 0, almost always, is extremely unreasonable. In addition to the fact that labor costs increase noticeably, the quality also falls on average (or labor costs grow quite strongly - there is much more debugging and testing).
-The ability to generate code, etc., which helps to greatly speed up development.
Regarding unnecessary abstractions, brakes, technologies. It is necessary to be able to choose the tools that are suitable for the task and the conditions for solving it. Often, it is more profitable to create a more resource-intensive application than it could be, but faster. This is certainly unpleasant and ugly, but this is the reality of our life.
There are, of course, reverse examples, where performance and resource consumption are critical, it is necessary to lick the code to the maximum, but they are much less common, and mostly in rather specific areas.
> How to remain a normal programmer not in the backyard, not to lose his grip and not get lost in all this?
Continually learn and specialize in a narrower area. This is true for any specialist, in fact, it is not directly related to programming ...
Only in order to speed up the development and make it more correct without unnecessary bicycles and crutches.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question