Will Java be replaced soon?

Source: Internet
Author: User
Tags hosting web hosting silverlight ruby on rails

For recent rumors that Java is about to exit the historical stage, you may want to know if it is time to stop using the Java platform and switch to the updated technology? Before making your judgment, please review and check the Java ecosystem and its competitors to see if these rumors have stood up. In other words, understand the current situation of the entire Java World and judge this platform objectively and fairly.

In the age of students, we may think of the predictions made by Thomas Malthus. He believes that the survival of mankind and the formation of a civilized agricultural system may not be able to bear the increasing population. On the other hand, this situation will inevitably lead to serious consequences, usually resulting in huge disasters or other natural disasters. He wrote: If there is no restriction on the population, it will increase proportionally. The material that people rely on to survive increases in the proportion of arithmetic. Compared with the latter, if you have a little understanding of these figures, you will be aware of the amazing growth of the population. This means that strict and persistent control over population growth is required to address the shortage of living materials. Material shortage will eventually occur in some places, and will inevitably seriously affect most of us.

Thomas Malthus published the Population Theory in 1798 ". Since then, we have been waiting to verify the "Malthusian test" on population growth ".

Programmers, especially those who use the Java platform and language, may have noticed that as the difficulty increases, various predictions and statistics suggest that the platform they choose will soon fall. A large number of candidates are eager to try: people nominate. net, Ruby, and even python as "the next generation of important technologies ".

There are striking similarities between the two Malthusian theories.

Malthus believes that because food is very important to human survival, the earth's output is limited, and the biological systems required for reproduction will not change, we will eventually reach a limit, at that time, the earth will not be able to bear the population burden. In other words, if we continue to survive in the current way, we will be doomed to an ending. At 1798, it is difficult to overturn Malthus's theory.

Similarly, in the past 18 months, the Java Community has seen a new trend: predicting the expiry date of the Java platform. From a few low-level news magazines calling it the technology of the 1990s s, to the rhetoric of technical speakers promoting its current situation, and to the various books that claim that we are "Beyond" the Java era, it is not difficult to find a point: with reasonable hint, code demonstration, logic or statistics, Java is declining.

Malthus missed the industrial revolution, and the latter triggered earth-shaking changes. In Malthus's life, he witnessed a huge leap in human agricultural productivity thanks to the invention of steam engines and cotton mills. These devices provide an important "missing connection" for his theory, which doubles the grain production, so that the agricultural system can defeat the "Gender passion" that creates a large population ". Subsequently, technological innovations in population control played the same role in reducing population growth, reducing the population burden and resulting in negative population growth in many Western countries, therefore, the situation is totally different from the logic of Malthus. All of this was unpredictable when Malthus wrote his paper, so that humans could survive beyond the limits of his predicted agricultural system, it also avoids a series of disasters.

What technical critics ignore is that the rise of alternative languages for Java virtual machines has led to huge changes. But don't trust my family's words easily. Let's check the arguments that support such arguments one by one to see if they can stand up.

Malthusian Java Prediction

Some people only reference some statistical descriptions, indicating that Java is no longer the most important language for programmers, and it simply determines that Java is already going downhill. Others pointed out that Java lacks some special features provided by its alternative environment, which are advertised as "requirements" for users and their applications ". There are also some people who have published (no factual basis) such remarks as "large enterprises will not use Java", which explicitly implies that if large enterprises do not use Java, it must be because this technology is not worth using.

To a greater extent, the Java platform and its ecosystem have long ago surpassed Simon Peyton-Jones's so-called "the threshold of immortality )", just like what C ++, C, COBOL, and other languages have experienced. These tools can always exist because they will continue to provide useful functions, or because the attempt to rewrite the code may be more costly than continuing to use and maintain the system as is (which of the two reasons is the specific language or system, there are a lot of disputes, and this is irrelevant to the purpose of this Article ).

Another argument is to let all smart people give up java and turn to platform X or language Y. In a BusinessWeek article in 2005, "Java? It's so nineties, quoted Peter yared, a former CTO of netdynamics, a long time ago, as saying "Java is as old as a dinosaur ". However, before we can understand the conflict of interests and reasoning logic, this article writes that all yared companies are trying? /Apache/MySQL/p-language) stack to recreate the application server experience.

(It is pointed out that the concept of Ruby is actually earlier than Java, and also includes Perl and python. This is somewhat rude, not to mention Linux, Apache and MySQL ...... Therefore, it is inconvenient for me to explain more here ).

Referencing a movie I like, "Life is painful, Your Highness. People who hold different opinions must have some attempts ". Or, to better interpret this topic, you can say, "It is painful to transition to a new platform, Mr. CTO. People who hold different opinions must have some attempts ". It may not be surprising that this is true for some java experts who have repositioned to other technical fields.

Let's look at another argument. It says, "The location of the top-level Java language is no longer guaranteed, so its decline must be miserable, so it is best to avoid this disaster ". This argument is based on the most basic premise, that is, if Java is no longer the best-selling technology in the world, it is not worth providing support for this language. However, such a statement is completely unreasonable after logical reasoning.

Statistics have long been considered unreliable (if improperly used), as Benjamin Disraeli cleverly explains: "There are three types of lies in the world: lies, curse and Statistics ". Statistical information can be used to demonstrate the most unreliable arguments. You only need to carefully select the required statistical information based on the arguments. Note the reference in BusinessWeek: "investigation ...... It shows that Java usage is gradually declining, while lamp and Microsoft? The. NET technology is gaining momentum ". Oh, it sounds bad. However, please continue, "according to the autumn survey by Evans, the percentage of developers who use Java as their preferred programming language in North America has dropped to 47.9%, compared with 2002 in the autumn of 51.4% ". Therefore, the usage of developers using Java as their preferred programming language has dropped by 3.5 Age points over the past six years.

Note that the "preferred" programming language is used here, which means that developers need to distinguish what is their "preferred" language. Considering a large number of XML configurations, developers using spring/hibernate/jsp Java stacks may be able to determine that Java is no longer their preferred language.

Pay attention to the Dynamic Language (Jython, jruby, groovy, and even javafx) emerging on the Java platform over the past six years. According to my colleagues and I (The speaker of "No fluff Just stuff) the app numbers obtained in informal voting at the nfjs activity can be easily interpreted by these dynamic languages as a drop of three percentage points.

Considering the reference from the same article: "In another survey, the use of PHP in North America has increased to 36.1% this fall, compared with 2002 in the same period in 26%. Its growth rate is almost as fast as that in Europe and Asia ". Considering that this is a different research series, it is only to show the growth of PHP, rather than the shrinking of the Java market. Congratulations to PhP, but any developer who has studied the enterprise environment can prove that production software deployment is not a zero-sum game as the author suggests. A large IT environment usually consists of a wide range of tools, platforms, languages, and products. In fact, we can almost achieve integration here, especially those mainframe components.

Speaking of hosts, in fact, COBOL was no longer the most important language decades ago. However, it continues to be used for cash payments, transfer deposits, payment of credit cards, and other major financial networks, even though many industry authorities have already declared its "death ". This is really good for the technology that should have been rotten in the grave; it reminds me of Mark Twain, who said, "gentlemen, the story about my death was severely exaggerated."

However, aside from the issue of statistics, the second problem is even more serious: Why don't we just discard the selected tool because it is not the best? Java has taken the lead in software development for nearly ten years. The game is over just as it "drops" to the second place? I even think that Java will be prevented from resuming the primary language just because of people's inertia. In fact, four of the 10 programmers will continue to use this language, this will ensure that Java will remain active for the next few decades. What's more ridiculous is that the growth of Java will be subject to an emergency and there will no longer be Java deployment. However, Java has been widely deployed throughout the industry, this ensures that Java continues to appear for a long time.

Although COBOL was declared dead, it was required that the number of people using it reach 6 to 7 digits each year.

Check evidence

However, pointing out the shortcomings of an argument does not prove another point of view, which is the same for this article. On the contrary, we should look at the Java language and platform from the perspective of criticism, and its strengths and weaknesses have withstood rigorous analysis. Java's longevity lies in its ability to meet the needs of the next decade, rather than being determined by any author or critic.

Finally, let's consider the components that constitute the Java platform:

* Java programming language. Frankly speaking, this is the part of the platform that best reflects its long life, especially when compared with more "modern" languages such as C #, groovy, (j) Ruby or Scala. Recently, a large number of suggestions have emerged to improve the language, such as adding closures to the language and other highly competitive proposals, proving that programmers are eager to have some features of other languages in Java. However, the joint success caused by the latest language enhancements in Java 5 should be the "Pay attention to the brakes" of all new major language changes. Some enhancements, such as for loops or annotations, are widely supported. However, some other enhancements, such as generics, are widely ridiculed and criticized. The fact is that there is no common acceptance of any language function in the developer community that it should have helped. This fact tells us: adding new language features to a language that has existed for more than a decade is tricky. If it is completed, it may also cause the language to crash. On the map of the Java platform, this area is marked with the warning of "Old sailors": "Here there are monsters !"

* Non-Java JVM programming language. Where Java stops, other languages provide improved and enhanced solutions. Groovy provides a dynamic and objective scripting solution around Java objects. (J) Ruby provides Ruby implementation on the JVM, opening up the world of rails and activerecordoffers for Java programmers. Scala and jaskell introduce functional concepts to the JVM to provide feasible solutions for concurrency problems. And so on. Because all these languages either compile into bytecode or use javax. the script API runs on the JVM as an interpreted language, so all the wealth of the Java ecosystem is available-and this is one aspect that Ruby developers cannot make the same declaration. In the map of the Java platform, this region is marked as the "country of opportunity ".

* Java virtual machine. Fortunately, the Java language has made significant revisions and fundamental changes. As the underlying foundation of the Java platform, JVM has not changed much. Recently, many people in the blog world have suggested making JVM more friendly to dynamic languages, which enables John rose, an engineer at sun, to provide a JVM revision, originally called multi-language Virtual Machine (mlvm), the name is now da Vinci machine (because it is tightly packaged in the Code ). The key here is that the proposed JVM change should avoid any event that may invalidate Sun's huge investment in JVM optimization. Those who make suggestions keep this in mind when designing the details.

* Java Standard Edition library. Java Standard Edition comes with a huge function set, with an order of magnitude greater than the C ++ standard library, and even many factors greater than its predecessor, Java 1.0, in addition, the Enterprise Edition library has not been taken into account (which will be discussed later ). On the surface, this looks like a natural advantage of Java developers, but you will find some minor problems after careful consideration. For beginners, the huge library means that many Java developers do not know that they are writing some actually existing code, which is collected in a package that was previously unknown. According to the time difference, the library may also encounter API design time troubles, many of which are due to the middle of 1990s, at that time, the developer's design class and library method were quite different from the design method in 2008. Some developers suffer too much abstraction. Just as the factory that created the object builder demonstrates, the interface instances created by these object builders may not necessarily implement methods that developers are interested in. However, although the JSE library is flawed, JSE still has advantages in general, especially when it is integrated with extensions like groovy provided to JDK (called gdk) this language supports enhanced integration.

* Java Enterprise Edition library. No technology can have a greater impact on the Community than EJB, and fortunately, the Java Community saw the rise of lightweight alternatives, spring and hibernate provide the final example, lightweight alternatives are ideal for these scenarios. However, if you do not consider EJB for the moment, the Java EE library is very successful-servlets and servlet containers provide motivation for a large number of Web applications across the Internet and the enterprise intranet, JMS provides access to a variety of message-oriented middleware systems. other well-known participants (such as JNDI) in the Jee field can execute their own tasks without complaint. The Jee library is likely to benefit from API re-design. This is the case with the JSE library. In general, the Jee library will meet the needs of Java programmers. The biggest problem is to know when the Jee library is required first. We will discuss the content in another article.

* Java-API-for-XML (Jax) Library. Although the name is part of the Jee library, the number and size of the Jax API are growing at a rate not commensurate with other parts of the Jee, and it is worth considering the Jax API from the context of Jee. In the last decade, despite the huge and common demand for XML support, it has been mitigated, especially for Web Services (WS -*) peripheral fields and normative camps (these specifications allow universal and easy interoperability with other technologies, including.. net ). Here, Java will undoubtedly require some type of revision, because more code is often required to complete important tasks for the sax, Dom, and Stax APIs, especially when compared to languages with more flexible XML support, such as E4X, Ruby, or Scala. Here, the idea of focusing on XML has changed significantly, from the early implementation of WS-* "Do not touch XML" to the restful method "I want to directly access XML and address it as a good and meaningful Uri ", this method also emphasizes the necessity of refactoring in the Jax field. In a map of the Java World, this area is marked as "(should) Obsolete ".

* Client Java. The beta version of Sun's recently revised "Java client" system has a pretty bad name "Java SE 6 Update 10 Beta", which provides enhanced client features, including the new swing appearance, called Nimbus. Unfortunately, there has always been a problem with measuring Java on the client, mainly because the applet dedicated to measuring has been used on the Internet for a long time, in addition, many of the design and architecture concerns for Web Hosting applications are centered on the creation of HTML, rather than generating the "rich client" application. With the increasing adoption rate, Java has to go through a long journey and catch up with its main competitors in this field. Flash and Microsoft's new technology Silverlight in this field make the situation more complex. Java may also lose its position completely. This does not mean that such a platform is "Extinct", but it will make the problem worse, when industry scholars and business magazines call it a clear example of Java technical weakness, be sure to inspire yourself!

* Server-side Java. This is really not controversial: Java is undoubtedly an established participant in the server field, especially when viewing non-Windows? Backend field options. The lamp series products may provide a front-end or vertical silo alternative, as Ruby on Rails does. However, when observing important server computing infrastructure, the image of the Java series products is very prominent. In fact, it is this leading position that prompted Microsoft to actively seek the WS-* specification, so that. Net code can at least invoke and cooperate with the established Java infrastructure. Microsoft recently recognized the more formal development of interoperability, and the "Interoperability lab" they set up at the University of Cambridge also reflected this.

* Ecosystem. No other platform has an ecosystem as diverse as the Java platform, but this often brings some trouble to Java developers ("which Web framework should I use ?"), In fact, many Java ecosystems penetrate into other environments, especially. net. Consider. net has made recent improvements inside and outside Microsoft: objectbuilder (dependency injection framework), asp mvc (MVC-based Web Framework), and nhib.pdf (part of hibernate) nant, msbuild (XML-based building systems similar to ant in terms of syntax or concept), and even Silverlight itself (hosting CLR within the browser allows execution of richer clients ). In many aspects, the. NET ecosystem has supported the Java Community for nearly five years, because. NET developers have discovered the same pain points they encountered five years ago. Java continues to learn from the. NET community (for example, the usefulness of Unified Communication APIs or the power of an explicit lightweight workflow engine ). This only demonstrates the fact that these environments are learning from each other and also shows that. Net does not make Java unnecessary.

There is no doubt that Java developers can add their own entries to this list to prove this argument: there are too many excellent things in the Java platform that are considered to be "Extinct", "dying", or even on the verge of "crashing ".

The King will return

The simplest fact is that Java, platform, ecosystem, environment, and development communities are far from dying, at least as far away as other languages or platforms currently in use. Even the strictest statistical fact filtering cannot deny Java's leading position.

In addition, even if Sun Microsystems fails, the platform will not die. Java developers from all over the world join up! Do not fear the bound chains: you will see that these chains do not actually exist. Thanks to the open-source Java platform, it is now called openjdk, not to mention other open-source "Clean Room" implementations of Java (APACHE harmony and soy latte are only two of them ), even if sun completely disappears from the earth, including IBM? Other entities, including Apache, Bea, and Oracle, can continue to provide JVM, libraries, and tools to support the overall ecosystem.

Will Java die out one day? Absolutely, but I firmly believe that Java will survive more than most of the languages used by today's programmers, just as COBOL does. It can even be longer than the second-generation Java programmers who have just stepped out of the university campus.

This is true for dinosaurs.

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.