The Java 3rd Library

import org.springframework.beans.factory.DisposableBean; import org.springframework.beans.factory.InitializingBean; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.PlatformTransactionManager; import org.springframework.transaction.TransactionDefinition; import org.springframework.transaction.TransactionStatus; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.support.DefaultTransactionDefinition; import org.springframework.core.io.Resource; import org.springframework.core.io.support.PathMatchingResourcePatternResolver; import org.springframework.core.io.support.ResourcePatternResolver; import org.springframework.util.ClassUtils; import org.springframework.util.Assert; import org.springframework.util.CollectionUtils; import org.springframework.util.ReflectionUtils; import org.springframework.util.StringUtils;

The Java 3rd Library

org.apache.http org.apache.commons.dbcp2 org.apache.commons.collections fastjson mysql-connector-java liquibase-core liquibase-maven-plugin commons.dbcp commons.collections commons-lang3 import org.apache.commons.lang.StringUtils; jedis junit dbunit spring-test-dbunit spring-test spring-boot-starter-test disruptor cxf-spring-boot-starter-jaxrs cxf-spring-boot-starter-jaxws cxf-rt-rs-service-description-swagger swagger-ui

The Java 3rd Library

import org.alibaba.fastjson.JSONArray; import org.alibaba.fastjson.JSONObject; import com.amazonaws.Request; import com.amazonaws.utils.StringUtils; import com.atomikos.datasource.xa.StringUtils; import com.fasterxml.jackson.core.JsonParseException; import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.core.io.JsonStringEncoder; import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.JavaType; import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.JsonMappingException; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.cache.CacheBuilder; import com.google.common.cache.CacheLoader; import com.google.common.cache.LoadingCache; import com.google.gson.Gson; import com.ibm.db2.jcc.am.re; import com.jayway.restassured.RestAssured; import com.jayway.restassured.path.json.JsonPath; import com.jayway.restassured.config.RestAssuredconfig; import com.jayway.restassured.response.Response; import com.jayway.restassured.response.ValidatableResponse; import com.jayway.restassured.specification.RequestSpecification; import freemarker.template.Template; import freemarker.template.TemplateException; import groovy.json.internal.JsonFastParser; import groovy.json.internal.ValueMap; import org.apache.ws.security.WSSecurityException; import org.apache.ws.security.util.Base64; net.sf.json JSONArray JSONNull JSONObject org.activiti.engine https://blog.csdn.net/fanxiangru999/article/details/79381966?utm_medium=distribute.wap_relevant.none-task-blog-baidulandingword-1 commons beanutils BeanUtils; collection

The Java 3rd Library: CXF

Apache CXF – JAX-RS Apache CXF – JAXRS Services Configuration Spring Boot CXF JAX-WS Starter cloud-enterprise-granny cloud-service-dq-api-rs apache / cxf A RESTful Web Service Project in Java JAX-RS with Spring and Apache CXF JAX-RS (JSR-311) JAX-RS: Understanding the Basics SpringBoot整合CXF,实现Restful api 与 WebService api da

The Java Standard Library

java io BufferedReader BufferedWriter ByteArrayInputStream ByteArrayOutputStream File FileFilter FileInputStream FileOutputStream IOException InputStream IntputStreamReader OutputStream OutputStreamWriter PrintWriter Reader Serializable StringReader StringWriter lang reflect Field Method InvocationTargetException math BigDecimal net HttpURLConnection URL URLConnection URLDecoder URLEncoder nio charset Charset security MessageDigest SecureRandom InvalidAlgorithmParameterException InvalidKeyException KeyManagementException NoSuchAlgorithmException NoSuchProviderException sql Date ResultSet ResultSetMetaData SQLException Timestamp text DateFormat DecimalFormat MessageFormat Normalizer NumberFormat SimpleDateFormat ParseException util ArrayList Arrays Base64.Decoder Base64.Encoder Calendar Collection Collections Comparator Date Enumeration GregorianCalendar HashMap HashSet HashMap Iterator LinkedHashMap LinkedHashSet LinkedList List Locale Map.

The Java Standard Library

import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.PUT; import javax.ws.rs.DELETE; import javax.ws.rs.Produces; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.QueryParam; import javax.ws.rs.core.Context; import javax.ws.rs.core.MediaType; import javax.servlet.http.HttpServlet; https://docs.oracle.com/cd/E19226-01/820-7627/6nisfjmk8/index.html

The Java Standard Library

javax inject Inject Named jms Message MessageListener TextMessage persistence Transient servlet Filter FilterChain FilterConfig ServletInputStream ServletOutputStream ServletRequest ServletResponse ServletException http Cookie HttpServlet HttpServletRequest HttpServletResponse HttpServletRequestWrapper HttpServletResponseWrapper transaction Transactional ws rs DELETE GET POST PUT Path PathParam Produces QueryParam core Context MediaType

The Java Standard Library

javax activation DataHandler MimetypesFileTypeMap crypto BadPaddingException Cipher IllegalBlockSizeException NoSuchPaddingException spec IvParameterSpec SecretKeySpec net ssl HostnameVerifier HttpsURLConnection SSLSession SSLContext TrustManager X509TrustManager script ScriptException security auth login LoginException xml bind Unmarshaller JAXBContext annotation XmlAccessType XmlAccessorType XmlElement XmlElementWrapper XmlRootElement XmlType namespace QName parsers DocumentBuilder DocumentBuilderFactory SAXParser SAXParserFactory soap SOAPBody SOAPBodyElement SOAPEnvelope SOAPMessage SOAPPart SOAPException

The Java Standard Library

Generic Array Lists 1 2 3 4 ArrayList<Employee> staff = new ArrayList<Employee>(); var staff = new ArrayList<Employee>(); // diamond syntax ArrayList<Employee> staff = new ArrayList<>(); 1 2 staff.add(new Employee("Harry Hacker", . . .)); staff.add(new Employee("Tony Tester", . . .)); 1 2 3 4 staff.ensureCapacity(100); ArrayList<Employee> staff = new ArrayList<>(100); int sz = staff.size(); staff. trimToSize(); 1 2 3 Employee e = staff.get(i); // use set only to replace a previously added element.

The Java Standard Library

Collections Interfaces Note that all the core collection interfaces are generic. For example, this is the declaration of the Collection interface. 1 public interface Collection<E>... The Collection Interface 1 List<String> list = new ArrayList<String>(c); The Collection interface contains methods that perform basic operations, such as int size() boolean isEmpty() boolean contains(Object element) boolean add(E element) boolean remove(Object element) Iterator<E> iterator() It also contains methods that operate on entire collections, such as

Open edX Devstack

Set up a WSL development environment Install WSL Open PowerShell (or Windows Command Prompt) and enter: 1 wsl --install For Ubuntu or Debian, update and upgrade packages, use the command in bash: 1 sudo apt update && sudo apt upgrade Proxy and Firewall 1 2 3 4 5 export HTTP_PROXY=http://172.22.32.1:10809 && export HTTPS_PROXY=http://172.22.32.1:10809 && export http_proxy=http://172.22.32.1:10809 && export https_proxy=http://172.22.32.1:10809 && export ALL_PROXY=http://172.22.32.1:10809 1 2 3 4 unset http_proxy && unset

Arch Linux Running OSX High Sierra In QEMU

Checking support for KVM 1 $ LC_ALL=C lscpu | grep Virtualization 1 $ zgrep CONFIG_KVM /proc/config.gz 1 $ lsmod | grep kvm 1 $ zgrep VIRTIO /proc/config.gz 1 $ lsmod | grep virtio 1 $ sudo modprobe virtio 1 sudo pacman -S qemu 1 $ sudo vim /etc/default/grub 1 GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet iommu=pt intel_iommu=on vfio-pci.ids=8086:a12f" 1 $ sudo grub-mkconfig -o /boot/grub/grub.cfg 1 $ git clone https://github.com/foxlet/macOS-Simple-KVM 1 $ git clone https://github.com/foxlet/vmra1n 1 $ cd vmra1n 1 $ sudo .

hackintosh

Step 1: Download – Get a copy of macOS Catalina Download Catalina 10.15 from the Mac App Store download it through a third party source such as gibMacOS. Step 2: Installer – Create the macOS Catalina flash drive Formatting the USB Drive Click Erase Set the following settings: Name: Hackintosher Format: Mac OS Extended (Journaled) Scheme: GUID Partition Map Click Erase Transferring the Catalina Installer balena-etcher Step 3: Catalina EFI Partition & Clover Files Mount EFI Partition Delete the folder called EFI in the partition you mounted (If it exists) Download Hackintosher-Catalina-10.

RabbitMQ

Using the Docker image 1 2 # latest RabbitMQ 3.12 $ docker run -it --rm --name rabbitmq -p 5672:5672 -p 15672:15672 rabbitmq:3.12-management Introduction Hello World! Python 1 $ python -m pip install pika --upgrade Sending 1 $ vim send.py establish a connection with RabbitMQ server: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 #!/usr/bin/env python import pika connection = pika.BlockingConnection( pika.ConnectionParameters(host='localhost')) channel = connection.

Mybatis Spring Boot

Creating a project 1 spring init -d=web --build=maven mysite Declare Dependencies 1 2 cd mysite vim pom.xml 1 2 3 4 5 <dependency> <groupId>org.liquibase</groupId> <artifactId>liquibase-core</artifactId> <version>3.10.2</version> </dependency> 1 2 3 4 5 <dependency> <groupId>org.mybatis.spring.boot</groupId> <artifactId>mybatis-spring-boot-starter</artifactId> <version>2.1.3</version> </dependency> 1 2 3 4 5 <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>8.0.20</version> </dependency> MyBatis-Spring-Boot-Starter will: Autodetect an existing DataSource Will create and register an instance of a SqlSessionFactory passing that DataSource as an input using the

Spring

Installation Install JDK Download jdk-8u261-linux-x64.tar.gz from Oracle 1 sudo pacman -S jdk8-openjdk 1 vim ~/.bashrc 1 export JAVA_HOME=/usr/lib/jvm/java-8-openjdk 1 source ~/.bashrc Install maven 1 sudo pacman -S maven 1 cp /opt/maven/conf/settings.xml ~/.m2/ 1 vim ~/.m2/settings.xml 1 2 3 4 5 6 <mirror> <id>alimaven</id> <mirrorOf>central</mirrorOf> <name>aliyun maven</name> <url>http://maven.aliyun.com/nexus/content/groups/public</url> </mirror> Installing the Spring Boot CLI Download the Spring Boot CLI 1 wget https://repo.spring.io/snapshot/org/springframework/boot/spring-boot-cli/2.3.3.BUILD-SNAPSHOT/spring-boot-cli-2.3.3.BUILD-SNAPSHOT-bin.zip Extract to a directory that supports file execution. 1

Spring Boot CXF JAX-RS Starter

Features Registers CXF Servlet with a “/services/*” URL pattern for serving CXF JAX-RS endpoints. Optionally auto-discovers JAX-RS root resources and providers and creates a JAX-RS endpoint. Note the use of CXF JAX-RS Clients in SpringBoot Application is covered in this section. Databases 1 2 sudo docker container start mysql-container-id sudo docker exec -it mysql-container-name mysql -u root -p 1 2 3 4 5 6 7 8 9 10 11 12 13 mysql> create database demo; mysql> USE demo; mysql> SET FOREIGN_KEY_CHECKS=0; mysql> DROP TABLE IF EXISTS `student`; mysql> CREATE TABLE `student` ( -> `id` int(10) NOT NULL, -> `name` varchar(100) DEFAULT NULL, -> `sex` char(6) DEFAULT NULL, -> `address` varchar(255) DEFAULT NULL, -> `age` int(10) DEFAULT NULL, -> PRIMARY KEY (`id`) -> ) ENGINE=InnoDB DEFAULT CHARSET=utf8; mysql> INSERT INTO `student` VALUES ('1', '', '', '', '22'); Creating a project 1 spring init -d=web,mybatis,mysql --build=maven mysite dependency 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 <dependency> <groupId>org.