是适合长期序列化的协议缓冲区吗?(is protocol buffers suitable for long term serialization?)
我正在考虑长时间在物体上存储增量的各种方法(30年是常见的情况)。 一种选择是使用单个增量表来存储每个对象的更改。 因为增量需要存储这么长时间,所以delta表会变得非常大,所以我考虑的选项是至少将它配对一点,不要将每个delta存储为字符串。
增量表主要是存储来自.NET的原语(
int
,long
,decimal
,string
等)。 delta表看起来像| RowIdentifier | FieldIdentifier | NewValue | Timestamp |
协议缓冲区(protobuf-net或其他一些protobuf实现)是否适合这种长期存储?
I am considering various ways of storing deltas on objects for long periods of time (30 years would be the common case). One option is to have a single delta table storing changes for every object. Because the deltas need to be stored for such a long time, the delta table will grow very large, so I was considering options to at least pair it down a bit by not storing every delta as a string.
The delta table would primarily be storing primitives from .NET (
int
,long
,decimal
,string
, etc). The delta table would look something like| RowIdentifier | FieldIdentifier | NewValue | Timestamp |
Is protocol buffers (protobuf-net or some other protobuf implementation) suitable for such long term storage?
原文:https://stackoverflow.com/questions/9502442
最满意答案
除非CacheDependency代码中存在严重的实现错误,否则第一个请求将锁定文件,其他请求将等待,直到删除锁定或更新缓存依赖关系的状态。
这种机制(CacheDepenendency)是为繁重的流量场景而设计的,我相信这样的事情已被涵盖......
Unless there is a serious implementation bug in the CacheDependency code, the first request will lock the file and the other requests will wait until the lock is removed or the state of the cache dependency updated.
This mechanism (CacheDepenendency) is designed for heavy traffic scenarios and I am sure such thing is covered...
相关问答
更多-
Spotify请求的限制(Limit of spotify requests)[2023-06-02]
国防部评论: 签名请求的速率限制根据端点,当前负载,原点等而有所不同,但始终应优于未签名请求的速率限制,并且对于正常使用应始终足够。 如果您经常使用速率限制,请考虑使用条件请求,使用缓存机制,调整分页限制等。 所以他们没有指定限制,他们动态计算,所以没有办法控制开发人员的请求限制。 Mod comment: The rate limit for signed requests varies according to the endpoint, current load, origin, etc., howe ... -
什么是“。”请求?(What is the response “.” requests?)[2021-11-07]
通常写成单个句点字符的区域是根区域。 如果您在响应的“其他”部分发送了一个查询并获得了有关根的信息,这意味着您发送问题的名称服务器不知道您询问的任何名称(这也意味着名称服务器是旧的,应该升级,但这完全是另一回事)。 如果你的问题是关于其他问题,那么我不明白你的问题。 The zone usually written as a single period character is the root zone. If you sent a query and got information about the ... -
我的问题是上面的ajax请求中的“url”属性是否采用绝对路径? 同源策略阻止JavaScript发出请求并读取响应,除非它是相同的主机,端口和协议。 这并不能阻止攻击者发出他们喜欢的任何HTTP请求(手动构建一个看起来与通过JS制作的一样微不足道)并且它不会阻止攻击者欺骗用户向攻击者发出任何请求喜欢(它确实阻止了攻击者获得对该请求的响应)。 攻击者无需使用PHP或任何其他服务器端语言来执行此操作。 此外,是否可以通过发送此类请求来破坏任何网站? 这取决于网站的编写方式。 您应该对设计为通过JavaScri ...
-
其中一个依赖选项是CExpressionDependency 。 您可以将当前缓存的beforeSave值与从loadModel调用获得的值进行比较。 After fighting with this I found the solution, don't feel it's completely pretty, but it does work. Any feedback on a cleaner way is much appreciated. $cache = Yii::app()->cach ...
-
安全问题:单个用户帐户的Drupal请求过多[关闭](Security question: excessive Drupal requests from a single user account [closed])[2022-05-06]
最有可能的是它没有1.重置密码仅在您收到电子邮件时才有用,而您只需要执行一次。 我认为3甚至不可能。 它很容易修复。 对于某些网站,我默认这样做。 使用hook_menu_alter,您可以删除密码重置的菜单项。 这将使所有用户无法重置密码。 另一个选择是在表单上包含一个CAPTCHA,因为它最有可能是机器人这样做。 使用现有模块应该非常简单。 Most likely it's some sort of no 1. Reset password is only helpful if you have the ... -
Codeigniter URL问题(Codeigniter URL question)[2022-09-25]
通过创建匹配的用户名,我看到您意识到用户可能会遍历其他有效路由。 您可以尝试将所有请求作为用户名路由,但为其他控制器(以及其他有效路由)提供触发器: // Route everything to users profile $route['(:any)'] = 'users/profile/$1'; // Route all requests after "my_trigger" as normal $route['my_trigger/(:any)'] = '$1'; *我不确定,但您可能需要在触发路 ... -
requests.get是一个阻塞调用。 它会等到响应到达之后才会执行其余的程序。 如果你想做其他事情,你可能会想看看asyncio或multiprocessing模块。 requests.get is a blocking call. It will wait until the response arrives before the rest of your program will execute. If you want to be able to do other things you will ...
-
最大。(Max. Requests Twitter)[2022-05-09]
目前,使用OAuth时,每小时有350个请求的速率限制。 我相信在使用基本身份验证时它会是150,这将在六月份弃用。 Currently, there is a rate limit of 350 requests per hour when using OAuth. I believe it's 150 when using Basic Auth which will be deprecated in June. -
本文简要介绍了JSON劫持。 假设您有一个Web服务,它向当前经过身份验证的用户返回一个信用卡号列表: [{"id":"1001","ccnum":"4111111111111111","balance":"2345.15"}, {"id":"1002","ccnum":"5555555555554444","balance":"10345.00"}, {"id":"1003","ccnum":"5105105105105100","balance":"6250.50"}] 以下是攻击的执行方式: 获 ...
-
关于Simulataneous请求的CacheDependency问题(CacheDependency Question Regarding Simulataneous Requests)[2023-08-28]
除非CacheDependency代码中存在严重的实现错误,否则第一个请求将锁定文件,其他请求将等待,直到删除锁定或更新缓存依赖关系的状态。 这种机制(CacheDepenendency)是为繁重的流量场景而设计的,我相信这样的事情已被涵盖...... Unless there is a serious implementation bug in the CacheDependency code, the first request will lock the file and the other requ ...