How much do you know about the latest features of Java 13?
JDK 13 was officially released on September 17, 2019.
The new version contains five main features
JEP 350: Dynamic CDS Archives
JEP 351: ZGC: Uncommit Unused Memory
JEP 353: Reimplement the Legacy Socket API
JEP 354: Switch Expressions (Preview)
JEP 355: Text Blocks (Preview)
Dynamic CDS Archives
First, we introduce CDS, which is called Class ...
Posted by Brown on Fri, 11 Oct 2019 01:05:18 -0700
6. AOP Search Enhancer for Spring Source Analysis 6
1. AOP use case of JDK dynamic proxy
public interface PersonService {
void sayHello();
}
public class PersonServiceImpl implements PersonService{
@Override
public void sayHello() {
System.out.println("lwh sayHello");
}
}
@Aspect
public class Proxy1 {
@Pointcut("execution(* *.sayHello(..))")
public void sayHell ...
Posted by realchamp on Thu, 10 Oct 2019 07:40:38 -0700
Spring 5 Source Deep Parsing - --- Generation of AOP Agent
After obtaining all the enhancements of the corresponding bean s, the agent can be created. Back to the wrapIfNecessary method of AbstractAutoProxyCreator, as follows:
1 protected static final Object[] DO_NOT_PROXY = null;
2
3 protected Object wrapIfNecessary(Object bean, String beanName, Object cacheKey) {
4 if (StringUtils.hasL ...
Posted by jonez on Thu, 10 Oct 2019 03:30:58 -0700
Strong Reference/Soft Reference/Weak Reference/Virtual Reference and GC Policy in Java
Before introducing various references, let's briefly introduce garbage collection.
What is garbage collection?
Garbage Collection (GC), as its name implies, is to release the space occupied by garbage and prevent memory leakage. Effective use of the memory that can be used to clear and recycle objects that have been dead or not used for a long ...
Posted by ravi.kinjarapu on Wed, 09 Oct 2019 15:40:03 -0700
java Foundation (17): Packaging Classes, System, Math, Arrays, Big Data Operations
1. Basic types of packaging
Recall that in the third article, when we learned about the basic data types in Java, we said that there are eight basic data types in Java, but these data are basic data, and it is very difficult to perform complex operations on them. What shall I do?
1.1 Summary of Basic Types of Packaging Classes
In the actual ...
Posted by khalidorama on Wed, 09 Oct 2019 04:00:22 -0700
Talking about AOP, AspectJ and Spring AOP
introduction
AOP (Aspect Orient Programming), as a supplement to object-oriented programming, is widely used to handle some cross-cutting system-level services, such as log collection, transaction management, security checking, caching, object pool management, etc. The key of AOP implementation lies in the AOP proxy created automatically by AOP ...
Posted by juline on Wed, 09 Oct 2019 03:45:08 -0700
Three Ways to Realize Timing Task in JAVA
Links to the original text: https://www.w3cschool.cn/quartz_doc/
Catalog
1. TimerTask with JDK
2. Use third-party packages: QuartZ Suitable for particularly complex business
3. Timing Task Management with Spring This is usually enough ...
Posted by Sherman on Wed, 09 Oct 2019 01:20:58 -0700
Apache Flink Zero Foundation Getting Started Writing the Simplest Hello World
Experimental environment
JDK 1.8
IDE Intellij idea
Flink 1.8.1
Experimental content
Create a Flink Simple Demo that counts the number of words from the stream data.
Experimental steps
First, create a maven project, where the pom.xml file is as follows:
<properties>
<flink.version>1.8.1</flink.version>
...
Posted by kavitam on Wed, 09 Oct 2019 00:08:13 -0700
lambada Expressions for Deep and Simple Functional Programming
lambda is a new feature of JDK 1.8. Functional programming can not be ignored. See:
lambda underlying implementation principle
1. The compiler generates a method for each lambda expression
The method name is lambda lambda $0,1,2,3,,1,2,3, but the expression referenced by the method does not genera ...
Posted by Darkness Soul on Tue, 08 Oct 2019 20:50:43 -0700
dubbo provider does not print error log resolution
Reason analysis:
By default, dubbo uses log4j as its logging framework. If you use a different logging framework, you may not have a log.
Solve:
It can be resolved by configuring the logger attribute of the application
//slf4j,jcl,log4j,jdk,log4j2
<dubbo:application logger="log4j2" />
T ...
Posted by jesirose on Tue, 08 Oct 2019 14:45:01 -0700