Spring transaction isolation level and propagation mechanism, spring+mybatis+atomikos for distributed transaction management

This article is reproduced in [ http://blog.csdn.net/liaohaojian/article/details/68488150] 1. The definition of a transaction: A transaction is a collection of multiple units of operation that are either not successful or successful.It must follow four principles (ACID). Atomicity: A transaction is the smallest unit of work that cannot be sep ...

Added by chrbar on Wed, 10 Jul 2019 19:29:01 +0300

Detailed description of <environments> configuration elements for Mybatis configuration

In this article, we continue to look at other configuration elements. Today's protagonist is our <environments> element, which is used to set up the database configuration we need to access. Let's first look at the configuration: <environments default="development"> <environment id="development"> <!-- Use jdbc transa ...

Added by phpforme on Tue, 02 Jul 2019 00:03:05 +0300

Java 7 enhanced try statement closes resources

Java 7 enhanced try statement closes resources Traditional ways of closing resources import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; class Student implements Serializable { private String name; public Student(String name) { this.name = name; ...

Added by GeoffOs on Tue, 25 Jun 2019 21:55:48 +0300

HAWQ Replaces Traditional Number Warehouse Practice (19) - OLAP

1. Introduction to OLAP 1. ConceptsOLAP is the abbreviation for On-Line Analytical Processing in English, meaning Online Analytical Processing.This concept was first proposed by E.F.Codd, the father of relational databases, in 1993.OLAP allows access to aggregated and organized data from business data sources in a structure called cubes.On-Line ...

Added by calevans on Sat, 22 Jun 2019 21:07:36 +0300

Configure how the database connection pool uses JNDI

1. JNDI: JNDI is ( Java Naming and Directory Inteface)Java Name directory interface. The role of JNDI is to bring resources into the server.You can think of JNDI as a repository.Put Java objects into JNDI. 2. Origin of data sources: In java development, use JDBC operations data base Several steps: 1. Use Class.forName (full pat ...

Added by fredriksk on Sat, 22 Jun 2019 20:18:12 +0300

Implementation of Dynamic Query by JDBC

A Summary 1. What is dynamic query? Random selection of several query conditions from a number of combinations into a DQL statement for query, this process is called dynamic query. 2. Difficulties of Dynamic Query There are many optional query conditions and combinations, so it is difficult to list them one by one. 3. Composition of Fina ...

Added by tc61380 on Sat, 15 Jun 2019 23:34:41 +0300

Spring JDBC 01 uses spring JDBC to operate database

1 What is spring JDBC Spring simplifies the workload of JDBC programming by abstracting JDBC access and consistent APIs. We just need to declare the SQL, call the appropriate Spring JDBC framework API, and process the result set. Transactions are managed by Spring and JDBC checked exceptions are converted to Spring consistent unchecked exceptio ...

Added by gigya on Thu, 13 Jun 2019 21:08:46 +0300

Spring's java configuration

Spring's java configuration 1. Spring's java configuration Java configuration is recommended by Spring 4. X and can completely replace xml configuration. 1.1 Use @Configuration and @Bean Spring's Java configuration is implemented through @Configuration and @Bean annotations: 1. @Configuration acts on classes, which is equivalent to an xml confi ...

Added by katierosy on Wed, 05 Jun 2019 00:14:22 +0300

Use and Operation of Database Connection Pool (DBCP)

Use and Operation of Database Connection Pool (DBCP) When using SQL statements to operate databases in java, it is often necessary to load the driver first, establish a connection, and then execute some SQL after successful connection. After executing SQL, it is necessary to consider whether to close the connection. When there is another SQL ...

Added by FredFredrickson2 on Mon, 03 Jun 2019 23:37:41 +0300

spring data jpa use (1)

spring data jpa A subproject of Spring. Used to simplify database access, support NoSQL and relational data storage. Its main goal is to make database access convenient and fast. Dedicated to reducing the amount of data access layer (DAO) development. The only thing developers need to do is declare the persistence layer interface, and the re ...

Added by kristy7 on Wed, 29 May 2019 22:38:51 +0300