Table of Contents Solve javax.persistence.RollbackException: Transaction marked as rollbackOnly Ask Abnormal 1. Apply logic 2. Persistence context issues 3. Restraint violations Approach 1. Check application logic 2. Review persistence context management 3. Check for constraint violations 4. Exception handling and logging 5. Reference documentation and community support in conclusion Resolving javax.persistence.RollbackException: Transaction marked as rollbackOnly […]
Tag: persist
k8s persistent storage PV, PVC
Table of Contents emptyDir storage volume hostPath storage volume nfs shared storage volume PVC and PV PV creation and destruction process NFS uses PV and PVC Build StorageClass + NFS to realize dynamic PV creation of NFS The life cycle of files on the container disk is short-lived, which causes some problems when running important […]
IDEA plug-in development-persistent configuration information solution
Write a custom directory title here Configuration information persistent storage How to save configuration files Implementation plan for each method 1.PropertiesComponent: 2.PersistentStateComponent: 3.Project Settings: 4. External files: 5. Database: 6. Encrypt data: 7. Custom configuration file format: Configuration file location Project-level configuration (stored under the .idea folder): Global configuration (stored in the global configuration file […]
Code implementation of custom persistence layer framework 1
Project structure Describe the project structure of the custom persistence layer framework? . ├── IPersistence │ ├── IPersistence.iml │ ├── pom.xml │ └── src └── IPersistence_test ├── IPersistence_test.iml ├── pom.xml ├── src └── target Specific code sqlMapperConfig.xml configuration file <configuration> <!– Store database configuration information –> <dataSource> <property name=”driverClass” value=”com.mysql.jdbc.Driver”></property> <property name=”jdbcUrl” value=”jdbc:mysql://localhost:3306/zdy_mybatis”></property> <property name=”username” […]
Linux memory management–high-end memory mapping kmap persistent kernel mapping
1 High-end memory and kernel mapping Although the vmalloc function family can be used to map page frames from high memory areas to the kernel (these are usually not directly visible in kernel space), this is not the actual purpose of these functions. It is important to emphasize the fact that the kernel provides other […]
kubernetes cluster orchestration – k8s storage (volumes, persistent volumes, statefulset controller)
volumes emptyDir volume vim emptydir.yaml apiVersion: v1 Kind: Pod metadata: name: vol1 spec: containers: – image: busyboxplus name: vm1 command: [“sleep”, “300”] volumeMounts: – mountPath: /cache name: cache-volume – name: vm2 image: nginx volumeMounts: – mountPath: /usr/share/nginx/html name: cache-volume volumes: – name: cache-volume emptyDir: medium: Memory sizeLimit: 100Mi kubectl apply -f emptydir.yaml kubectl get pod […]
AutoX – Lazy loading of objects and image resources + Storage persistence
AutoX-lazy loading of objects and image resources + Storage persistence 1. Usage scenarios There are many scenarios that require lazy loading. The first time I needed the lazy loading function was when writing a game automation script. I needed to detect the coordinates of an item in advance before subsequent clicks. The item’s position on […]
Redis persistence RDB + master-slave replication principle + Redis persistence AOF
1. RDB for redis persistence Redis provides 2 different forms of persistence. RDB (Redis DataBase) AOF (Append Of File) 1.What is RDB Write a snapshot of the data set in the memory to the disk within a specified time interval, which is also called a Snapshot in the jargon. When it is restored, the snapshot […]
sentinel rule persistence-rule synchronization nacos-the most standard configuration
Official reference document: Dynamic rule expansion · alibaba/Sentinel Wiki · GitHub The code that needs to be modified is as follows: In order to facilitate the integration of nacos in subsequent versions, let’s briefly talk about the integration ideas. 1.Change pom Modify the scope of sentinel-datasource-nacos Will <dependency> <groupId>com.alibaba.csp</groupId> <artifactId>sentinel-datasource-nacos</artifactId> <scope>test</scope> </dependency> Change to <dependency> […]