简体   繁体   English

通过API导入大数据

[英]Importing large data by API

I am trying to develop a system in which I will sync my database with 3-Party database by provided API. 我正在尝试开发一个系统,我将通过提供的API将我的数据库与3方数据库同步。 The API has format in which we can provide From-Date and To-Date API具有我们可以提供From-Date和To-Date的格式

Problems 问题

  1. There is no API which gives me only modified records. 没有API只给我修改过的记录。
  2. The data is too large (1000 records/day average) 数据太大(平均每天1000条记录)
  3. Need a scheduler so all the records are updated automatically 需要一个调度程序,以便所有记录自动更新
  4. I also need to keep track of modified records(which is the biggest problem as I can't get them by modified date) 我还需要跟踪修改后的记录(这是最大的问题,因为我无法通过修改日期获取它们)

Note : As per the previous requirement i Have already developed the system in which i can Specify the From-Date and To-Date the record get updated (its completed with the GUI no ajax was uses). 注意:根据之前的要求,我已经开发了一个系统,我可以在其中指定记录的日期和日期更新(使用GUI完成,没有使用ajax)。 and even if I request 1 day records the system get time out error. 即使我要求1天的记录,系统也会出现超时错误。

NOTE 2 : I really should no say but the client is too strict (DUMB);( he just need the solution nothing else will do 注2:我真的不应该说,但客户端太严格(DUMB);(他只需要解决方案别的什么都不会做

Assuming that the data doesn't need to be "fresh" can you not write a process to run hourly / nightly fetching that days worth of data and processing it into your DB? 假设数据不需要“新鲜”,您是否可以编写一个进程来每小时/每晚运行那些数据并将其处理到数据库中?

Obviously this would only work if you're sure previous records are not updated? 显然,这只有在您确定以前的记录未更新时才有效吗?

Does the API provide batches? API是否提供批次?

Why did you you choose a web client with Ajax to process this data? 为什么选择使用Ajax的Web客户端来处理这些数据? Would a windows / console application be better suited? Windows /控制台应用程序会更适合吗?

If the data is too big to retrieve by any given query, you're just going to have to do it by ID. 如果数据太大而无法通过任何给定的查询进行检索,那么您只需通过ID进行检索即可。 Figure out a good size (100 records? 250?), and just spin through every record in the system by groups of that size. 找出一个好的大小(100条记录?250?),然后按该大小的组旋转系统中的每条记录。

You didn't say if you're pulling down data, pushing up data, or both. 你没有说你是在拉下数据,推高数据,还是两者兼而有之。 If you're only pulling it down, then that's the best you can do, and it will get slower and slower as more records are added. 如果你只是把它拉下来,那么这是你能做的最好的,随着更多记录的增加,它会越来越慢。 If you're only pushing it, then you can track a "pushed date". 如果您只是推动它,那么您可以跟踪“推送日期”。 If it's both, how do you resolve conflicts? 如果是两者,你如何解决冲突?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 REST API放置大数据 - REST API Put large data SSIS包是导入和导出大量数据的最佳解决方案吗? - Is SSIS packages are best solution for importing and exporting the large amount of data? C#将大量数据从CSV导入数据库 - C# Importing Large Volume of Data from CSV to Database 大数据量的 Web API 中的 502 错误 - 502 Error in Web API for large size of data 处理Web API返回的大型JSON数据 - Dealing with large JSON data returned by Web API 在REST API中返回大量数据 - Return large volumes of data in REST API 使用线程通过API为成千上万的用户导入数据 - Importing data through API for thousands of users by using threads 将数据从(大)文件Excel导入datagridview然后导入数据库 - 为什么插入数据库需要这么长时间并且不保存所有数据? - Importing data from (large) file Excel to datagridview and then database - why inserting to database takes so long and doesn't save all data? API调用因超出大量数据而超时 - API call getting timed out for large amout of data 使用DirectorySearcher API读取/处理大量数据 - Read / Process large number of data using DirectorySearcher API
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM