node.js - nodejs 开发效率比java更快吗?
PHP中文网
PHP中文网 2017-04-17 14:28:09
0
8
653

请问做web程序,nodejs真的比java 开发效率高吗?java的三大框架我很熟悉,我知道nodejs搭建一个能跑起来的web很容易,但一个应用程序不是搭建起来用的时间长短那么简单,还要看开发数据库连接是否方便,模块之间连接是否方便等。

PHP中文网
PHP中文网

认证高级PHP讲师

reply all(8)
伊谢尔伦

Anyone who talks about model selection out of the status quo is a rogue.
Selection depends on needs and developer.

I think what you actually want to know is the advantages and disadvantages of nodejs.

I’ll just talk about it

Advantages:

  1. Based on javascript is its biggest advantage. This gives nodejs a large number of potential users.

  2. nodejs is easy to learn. If you understand most of the knowledge about web development, you can quickly develop a simple web app by following tutorials and using appropriate frameworks.

  3. Nodejs is based on the event system and developed for web development. It has advantages in io performance (in fact, it forces asynchronous programming).

  4. Nodejs is very popular and the community (open source) is very active. (Related to 1 but not directly)

  5. That’s what you said, the code density is high. Short code can complete the development tasks.

  6. (from 4) Various libraries and frameworks are numerous, new and of good quality. Library to connect to database or something.

Disadvantages:

  1. Nodejs is difficult to master. It’s not that ordinary people can’t do anything with nodejs, but because it is a dynamic language and requires high coding quality. Otherwise, you will fall into endless debugging.

  2. CPU cost is high. Also because of dynamic languages.

  3. Single process/process stability is slightly less stable. This can be easily solved with pm2, but it is also a disadvantage.

  4. It is based on asynchronous, so there is something called callback hell, which will be ugly if written in es5.

刘奇

First of all, this question is difficult to answer. In addition to the various conveniences provided by language, framework, and libraries, development efficiency also depends on proficiency. Comparisons at the language level using nodejs or java are meaningless. The language debate has never stopped!

迷茫

I have played express before when I had free time, and it felt pretty good.
Springboot can be used for rapid Java development.
In terms of speed, there are still many factors to consider, but generally speaking, scripting language development is faster.

PHPzhong

In terms of maturity of development tools, nodeJs is far behind Java

黄舟

In fact, the difference between the quality of the language itself is not very big, it mainly depends on the person who uses it! People who know how to use it can write good programs in any language. If they don't know how to use it, they can't understand it in any language. There are pitfalls everywhere.

PHPzhong

Most of the time it will be faster. Node.JS online execution

迷茫

Java has never been known for its development efficiency. Long project cycle is a common problem of Java Web.
When it comes to development efficiency, Node can only bow its head in front of PHP.
This is why it is the most PHP, a grassroots language with no background from a big company, is not favored but can thrive for a long time.
Simple and practical things will never go out of style. This is the hard truth.
This is why AngularJS, which has a background in Google, is still unable to shake it. Reasons for the jQuery ecology.
Even if those senior front-end advocates advocate that AngularJS is good, it will not help because the learning cost is high, the results are not obvious, and novices cannot play it, which undermines self-confidence.
And things like PHP+jQuery, It is very friendly to novices, and the in-depth function is also very powerful, which can help beginners build confidence.

Ty80

Three to five times faster

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template