The database is based on records, but the program does not find the problem

Source: Internet
Author: User

Background:

The company provides a page to manipulate the database,

1. Update a record with DML

2. Use SQL Select to query out new records

3. Java program read this record directly, found that the old record

4. Go out for a cup of tea and find a new record

Problem Finder

1. Find the DBA to verify that the schema is correct based on the configured database

Ok

2. Verify that the library is a standby library

Is

3. Confirm the main library is responsible for reading and writing, library read only

Reason:

Synchronization latency issues for the main and standby libraries can be explained

1. Use update to enter the main library

2. SQL Read is also routed to the main library (dynamic routing)

3. Java program read from the library, no synchronization

The 4.java program reads from the library and the data is synchronized.

The database is based on records, but the program does not find the problem

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.