Home > Net >  A great god, and of all stripes have better advice to every five open a thread to update data?
A great god, and of all stripes have better advice to every five open a thread to update data?

Time:11-17

ORM use EF6, such as: is there a better way of advice or to every five open a thread to update data?

Logic, for example: article database with 1000 data need to be updated, but this article 1000 data interface need to request a third party or to update the data to the results, and needs to be updated regularly, every 3 s are going to finish the 1000 data

CodePudding user response:

Urgent urgent, online, etc

CodePudding user response:

This business is reasonable? Should not need to update? Assumptions needed to determine whether existing data in an update cycle if the has been updated the access, is not an update request update cycle, saying third-party interface is a third party not controlled,

CodePudding user response:

Asynchronous tasks can use
 Task. Run (()=& gt; {
.
});
to encapsulate and start-up, if internal code is asynchronous, plus the async keyword can, in the front ()

As for database update, in fact, a relational database is usually a high efficient system bottlenecks, because a relational database server will automatically start the transaction of data protection, at least in the record level has a write lock, can't allow you to concurrent modification related data records, so to truly developed high-performance multitasking system, usually should learn some distributed concurrent framework, such as. Net Orlean,

CodePudding user response:

High performance of the system design is based on the concept of "distributed network object caching services", there are a lot of people with a relational database "to add and delete" concept will come to the work, in fact, the real performance of persistent data of the system is not fall to the ground, and the performance is higher than relational database hundreds, and the automatic management of dozens of units, hundreds of servers (only one server is the same, of course) on the hundreds of millions of concurrent object, pay attention to is "objects" rather than a database record,

CodePudding user response:

How is done now
  • Related