[This article turns to self-music bytes]
Python is TIOBE’s Programming Language of 2020. This is undoubtedly a powerful word for me, who has been writing Java programs for 20 years.
The way I used to make fun of Delphi and Ruby is very similar to the way I have been made fun of in recent years.
The rapid development of Python, the passing of Java, and the sunset of Ruby are due to the factors of the language itself, the promotion of various manufacturers, and the development of its ecosystem. But the author thinks that those are superficial phenomena, the biggest influencing factors are determined by the social demand for information application and digital application.
The vitality of a high-level language depends mainly on its ability to solve the need for rapid replication of various software solutions in various industries at a low cost. These costs can include human resources, unit timeliness, demand matching, and the operational efficiency required by the industry.
And as a programmer, especially in the current material life environment programmer, our choice of a language often depends on established on the basis of the next dimension, such as how jobs, learning how costs and wages, how sustainable, volume within the risk and even bet on industry trends. Java and Python both perform well in their respective areas of expertise as far as the base is concerned, but they also test each other’s areas of expertise (Java here refers to the JVM family of languages, including but not limited to Groovy, Scala, and Kotlin). Didn’t Java and C# test each other in the past?
About the Java Version
Java community released two versions of JDK14 and JDK15 in the middle of 2020. However, the majority of domestic Java users are using JDK 8 or below, and the number of organizations using JDK 11 in production environment is still small (but increasing). Even systems developed using Oracle JDK 11 will mostly run in the OpenJDK environment.
The main reason for this is that most of the attention is focused on the LTS version of the JDK, and Oracle has promised to provide update support for the TWO LTS versions of JDK8 and JDK11 until 2030 and 2026 respectively. If your organization is still using previous versions of JDK8, it is recommended that you upgrade to at least JDK8.
The latest version of JDK14 and JDK15 is not a TLS version, but it is a preview of some of the most important features in the JDK17 LTS release.
Since JDK 9, the Oracle JDK has been updated every six months, and the corresponding Open JDK has also been updated every six months after the release of a new Oracle JDK.
Some of the most important feature updates in JDK 14 and JDK 15 are:
- Update to the GARBAGE collector: THE CMS garbage collector is officially deprecated, the ParallelScavenge + SerialOld GC combination is deprecated, the ZGC garbage collector is normalized, and the G1 garbage collector is optimized to remain the default garbage collector.
- Regarding the use of the pattern matching syntax: the pattern matching syntax has been released in two consecutive preview releases, so there is a high probability that it will be an official feature in JDK17. The match pattern is a syntactic optimization of the Instanceof modifier.
- Improvements to NullPointerExceptions: The improved NullPointerExceptions will help users quickly locate null Pointers, both when called with multiple consecutive methods.
- Dependency closure/interface closure: Interface closure was actually used internally in previous versions of JDK15, which made interface closure available to end users as a preview feature. I estimate that this feature will most likely be released as an official feature in the stable JDK17 release.
- Record compact syntax: This feature also has two consecutive preview releases and is likely to be released as an official feature in JDK17. I wonder if the Oracle team borrowed Lombok’s features from the compact syntax
Spring ecological
2.1 Spring Boot update
In November 2020, Spring Boot released version 2.4.0, which is a GA release, and Spring Cloud has been updated to match. JDK15 features are supported in version 2.4.0, but this release does not recommend immediate updates in the official environment.
In fact, Spring Boot maintained two major releases, 2.3.1-2.3.6, and 2.4.1, this year. The author currently uses version 2.2.X most in his actual work, and version 2.3.X has also been adopted in several recent projects. Since Spring 2.3.X, the build method of Spring Boot has been switched from Maven to Gradle. This is the same as my previous conjecture. I pushed Gradle to be used in the project construction process several years ago, and it has been proved to be effective in the implementation process.
Gradle has been on the verge of catching up with Maven in terms of usage for many years, and the new version of Spring Boot built with Gradle is sure to provide a positive example for the promotion of Gradle.
2.2 Spring Cloud update
With the Spring Boot update, a new version of Spring Cloud has been released. In 2020, version 2020.0 of Spring Cloud was released, which does not use the naming method of previous Spring Cloud versions (the last version was named Hoxton, which was named after the London Underground station in the UK). The new version uses the calendar version named 2020.0.x. The release officially removed multiple Netflix integrated components, such as Netflix-Hystrix, Netflix-Ribbon, Netflix-Zuul, Netflix-Turbine, Only Netflix Eureka remains (and is no longer recommended), so Netflix’s role in the new version of Spring Cloud is getting smaller and smaller.
In fact, the actions of Spring Cloud to replace various components of Netflix have been gradually clear in the previous version, and the official Spring Cloud also provides several replacement solutions for components. (After listing these replacement solutions, it can be seen that the technology stack of Spring community is really updated very quickly. A little not careful is easy to omission update, and then a little not careful is easy to volume) :
- Service registry: Nacos, from SpringCloudAlibaba, if Consul has been used in the project before, it is recommended to continue to use Consul; For new projects or products, it is recommended to switch to Nacos. Other components that are still supported include ZooKeeper, Consul; The use of Eureka is no longer recommended, and if it is still used on projects or products, you can consider completing the upgrade as soon as possible with minimal technical cost. In my opinion, THE reason why Nacos is behind us is that it has a high degree of integration and significantly reduces the user’s learning cost
- Service invocation: openFegin. Some readers may confuse openFegin with Fegin, but they are not the same thing. Fegin is a component provided by Netflix to the Spring community and has been replaced by openFegin
- Call load: LoadBalancer. Ribbon has been officially replaced in the new version
- Circuit breaker and Upgrade and downgrade: Resilience4J and Sentienl are both officially recommended optional versions in the latest version. Sentienl comes from SpringCloudAlibaba, and there are more domestic usage and discussion materials. It is recommended that Hystrix be replaced with Sentienl, of course, if the cost of the replacement is high for the reader’s organization, then it can be done step by step because Hystrix has been around for a long time
- Service Gateway: Personally, ZUul has worked well for various projects and products, but as more products and projects have been developed, the author has moved to Gateway. It works really well. I recommend it
- Service configuration: The Config component still exists in the latest version of Spring Cloud, but if your reader’s organization uses Naos, it is recommended to use Nacos instead
Without enumerating the rest, let’s summarize the development trend of Spring Cloud: Component integration gradually increases. Various components provided by Netflix in the initial version have been gradually removed (mainly because the update frequency of the latter cannot meet the requirements of the Spring community), and components provided by SpringCloudAlibaba account for a gradually increasing share in the Spring community. It is even possible to guess that in the near future the technology lines of Both SpringCloudAlibaba and native SpringCloud will gradually merge. In fact, it is a good choice for readers to use SpringCloudAlibaba directly
Java perimeter dynamics
3.1 UPDATE of IDE tools
Eclipse has been losing a lot of usage in recent years, mostly because most developers have switched to Intellij IDEA, which is available commercially for a fee, but that hasn’t stopped developers from using it. In my opinion, neither Eclipse nor IDEA is an absolute winner. Vendor support and community activity play a major role in the development of Eclipse and IDEA. It depends on personal preference, after all, it is naive to think that you can acquire new skills by changing a tool.
In December 2020, Intellij released the latest version of IDEA, 2020.3 (including multiple editors), bringing the total number of available versions of Intellij IDEA to three in 2020. Several new/modified features have been added/modified in this release, including:
- The welcome page has undergone significant changes. A learning TAB has been added on the welcome page to facilitate users’ learning of IDEA.
- IDEA already has complete Git support, integrating Git options directly into the top-level menu and adding separate Git search results items to the search TAB.
- Other optimizations include code expressions, reader modes, debugging improvements, performance analyzers, memory snapshots, and more.
3.2 Centos 8 will soon cease maintenance
CentOS 8 will end in 2021, but CentOS 7 will continue to operate until 2024, so users of the most popular versions of CentOS 7 will not be affected for the time being.
In addition, after CentOS 8 stops updating, users can use CentOS Stream 8 to replace it in non-production environments. However, I personally think the best option is to switch directly to Ubuntu Server.
3.3. In enterprise applications, Zhongtai is in the ascendant
In fact, ali started to implement the technology strategy of small front desk and big middle desk internally in 2015. In 2018, all industries began to gradually solve such resource centralization solution after seeing the successful experience of Ali. Retail, logistics, fast consumer goods, consumer goods, mutual gold and other industries, there are a number of enterprises began to try out the Taiwan line. There are also a number of IT companies that are focusing on enterprise-level and Taiwan-based solutions and advertising their success stories to customers. But is it true that all enterprises are suitable for the middle stage?
I have my doubts. We should know that Ali has promoted the medium platform, but also the medium platform of the e-commerce industry, referred to as the medium platform of e-commerce.
From a purely technical level, China strategy involves to the enterprise in a certain number of system integration problems, but not all companies are ali as fast iterative nature of system, the author personal contact with customers, some customers still use the old system of 10 years ago, the integration of these systems will be more difficult technical problem; Considering from the business level, not all enterprises have dozens of business systems and thousands of business processes. Can the centralization of a few systems achieve the purpose of simplifying business? From an IT hr perspective, forget IT.
With a year to go, and the impact of the pandemic on both individuals and the industry clearly evident, programmers should think more about how to avoid embedding, their ability to resist risks, and not stay in their comfort zone for too long.
2021, with your mutual encouragement.