couchdb

C#, HTTPClient - IfMatch format requirements?

无人久伴 提交于 2020-01-04 05:57:05
问题 I am using the System.Net.Http.HttpClient found in .Net 4.5 in conjunction with CouchDb. I have a revision of a document being: 3-789d4d2b33bf4505f8f23fd4a1025a4e . The issue is that I can't get that to work with the If-Match header flag on the request. var req = new HttpRequestMessage(HttpMethod.Delete, url); req.Headers.IfMatch.Add( new EntityTagHeaderValue("3-789d4d2b33bf4505f8f23fd4a1025a4e")); The EntityTagHeaderValue causes a format exception: "The format of value '3

Can someone explain me Cascading and FetchType lazy in Ektorp?

▼魔方 西西 提交于 2020-01-04 03:02:08
问题 I am new to CouchDB and Ektorp (I ACTUALLY started today to try to work with it). The most detailed documentation I have found to help me getting started is this one: http://www.ektorp.org/reference_documentation.html#d100e394 My use case is that I want to save a very complex class as a document (I have managed that so far), but I do not want to load all the fields all the time (since some of those are potentially big collections of other simpler documents). Here is an example of what I have

The _replicator database is not scalable or my design needs tweaking

萝らか妹 提交于 2020-01-03 18:33:47
问题 I think it is important that I elaborate on where I am coming from so that you can understand my use case, please bear with me. Background: I’m looking to migrate my app from CouchDB 1 to 2 and this migration is going to take a decent amount of work. I just want to double check that I’m not reinventing the wheel and make sure that there isn’t a better design to what I will elaborate on below, especially since CouchDB 2 appears to have some awesome new features. Consider the following

The _replicator database is not scalable or my design needs tweaking

半城伤御伤魂 提交于 2020-01-03 18:33:09
问题 I think it is important that I elaborate on where I am coming from so that you can understand my use case, please bear with me. Background: I’m looking to migrate my app from CouchDB 1 to 2 and this migration is going to take a decent amount of work. I just want to double check that I’m not reinventing the wheel and make sure that there isn’t a better design to what I will elaborate on below, especially since CouchDB 2 appears to have some awesome new features. Consider the following

How does CouchDB calculate the Revision number

混江龙づ霸主 提交于 2020-01-03 09:10:11
问题 I'm trying to understand how CouchDB calculates the revision id for a document. I notice from the source that it's calculated by this bit of code here: couch_util:md5(term_to_binary([Deleted, OldStart, OldRev, Body, Atts2])) And I know that if I create a new empty document with no attachments, CouchDB always gives it a revision of 1-967a00dff5e02add41819138abb3284d which, in decimal is <<150,122,0,223,245,224,42,221,65,129,145,56,171,179,40,77>>. However, if I type the following into the

PouchDb Replicate of single document causes huge memory usage, then crash

烂漫一生 提交于 2020-01-03 05:07:24
问题 I have a situation where live sync is refusing to get some documents on it's own, making PouchDb.get return saying the document is not found (despite it being there in CouchDb that it is replicating from). Reading through the documentation, it suggests doing a manual replicate first, then a sync. So I changed my code to first replicate docId='testdoc'; return new Promise(function (resolve, reject) { var toReplicate=[docId]; console.log("replicate new ", toReplicate); var quickReplicate = self

How to connect pinoccio to apache couchdb

不羁岁月 提交于 2020-01-03 03:25:12
问题 Is there anyone using the nice pinoccio from www.pinocc.io ? I want to use it to post data into an apache couchdb using node.js. So I'm trying to poll data from the pinnocio API, but I'm a little lost: schedule the polls do long polls do a completely different approach Any ideas are welcome Pitt 回答1: Sure. I wrote the Pinoccio API, here’s how you do it https://gist.github.com/soldair/c11d6ae6f4bead140838 This example depends on the pinoccio npm module ~0.1.3 so make sure to npm install again

Database to choose for game

元气小坏坏 提交于 2020-01-03 02:27:08
问题 I'm working on a game (something like chess) where every move needs to be saved into a database per move. Since it's very important that both reads and writes are fast, and I don't need complex queries, I'm probably going to go with a NoSQL solution. Which one though? I'm thinking about MongoDB but will its durability be an issue? It's not the end of the world if some game movelists are corrupted, but would be problematic if it occurs too often. Suggestions? Thanks. 回答1: Last time I looked at

Zend Framework and Couch DB

穿精又带淫゛_ 提交于 2020-01-02 10:22:46
问题 Does Zend Framework has native Couch DB support? I found only Zend_Couch by Matthew Weier O'Phinney. http://framework.zend.com/wiki/display/ZFPROP/Zend_Couch+-+Matthew+Weier+O'Phinney Thank you. 回答1: Not yet. The proposal is Ready for Review, so it likely end up in ZF sooner or later. You can either wait or use PHPillow 回答2: Nope, but there are a few libraries available out there already. I personally like http://www.saggingcouch.com because it's simple and light weight (disclaimer: I

scrapy items are not JSON serializable while storing them to couchdb

别等时光非礼了梦想. 提交于 2020-01-02 08:01:49
问题 items.py classes import scrapy from scrapy.item import Item, Field import json class Attributes(scrapy.Item): description = Field() pages=Field() author=Field() class Vendor(scrapy.Item): title=Field() order_url=Field() class bookItem(scrapy.Item): title = Field() url = Field() marketprice=Field() images=Field() price=Field() attributes=Field() vendor=Field() time_scraped=Field() my scrapper from scrapy.contrib.spiders import CrawlSpider, Rule from scrapy.contrib.linkextractors.sgml import