{"action":"created","issue":{"url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/278","repository_url":"https://api.github.com/repos/fergiemcdowall/search-index","labels_url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/278/labels{/name}","comments_url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/278/comments","events_url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/278/events","html_url":"https://github.com/fergiemcdowall/search-index/issues/278","id":151097811,"number":278,"title":"Replication and Options (fieldsToStore)","user":{"login":"iSOcH","id":10696022,"avatar_url":"https://avatars.githubusercontent.com/u/10696022?v=3","gravatar_id":"","url":"https://api.github.com/users/iSOcH","html_url":"https://github.com/iSOcH","followers_url":"https://api.github.com/users/iSOcH/followers","following_url":"https://api.github.com/users/iSOcH/following{/other_user}","gists_url":"https://api.github.com/users/iSOcH/gists{/gist_id}","starred_url":"https://api.github.com/users/iSOcH/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iSOcH/subscriptions","organizations_url":"https://api.github.com/users/iSOcH/orgs","repos_url":"https://api.github.com/users/iSOcH/repos","events_url":"https://api.github.com/users/iSOcH/events{/privacy}","received_events_url":"https://api.github.com/users/iSOcH/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2016-04-26T10:26:49Z","updated_at":"2016-04-26T12:57:10Z","closed_at":"2016-04-26T12:53:23Z","body":"i'm trying to create and replicate an index with `fieldsToStore` set on initialisation.\r\nwhen querying that index after replication I get hits, but the documents returned from `search` are always `undefined`.\r\nthe same operation without `fieldsToStore` returns the documents as they were stored.\r\n\r\nwith `fieldsToStore`\r\n```\r\n{ totalHits: 1,\r\n  totalDocsInIndex: 3,\r\n  documentFrequencies: { '*￮austausch': 1 },\r\n  fieldWeight: { '*￮austausch': 0 },\r\n  query: [ { AND: [Object], NOT: [Object] } ],\r\n  buckets: [],\r\n  categories: [],\r\n  hits:\r\n   [ { id: '0.7027325540540822,39',\r\n       score: 0,\r\n       tfidf: [Object],\r\n       document: undefined } ] }\r\n```\r\n\r\nwithout `fieldsToStore`:\r\n```\r\n{ totalHits: 1,\r\n  totalDocsInIndex: 3,\r\n  documentFrequencies: { '*￮austausch': 1 },\r\n  fieldWeight: { '*￮austausch': 0 },\r\n  query: [ { AND: [Object], NOT: [Object] } ],\r\n  buckets: [],\r\n  categories: [],\r\n  hits:\r\n   [ { id: '39',\r\n       score: 0.4230871553996776,\r\n       tfidf: [Object],\r\n       document: [Object] } ] }\r\n```\r\n\r\ndo I have to set `fieldsToStore` (or something similiar) when receiving data from a replication? i empty the target index using `flush()` before calling `replicate`\r\n\r\nanother difference I noticed between source and target of replication (also only when using `fieldsToStore`) is in the id field: on source I get `id: '39'` and on target it's `id: '0.7027325540540822,39'`"},"comment":{"url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/comments/214732256","html_url":"https://github.com/fergiemcdowall/search-index/issues/278#issuecomment-214732256","issue_url":"https://api.github.com/repos/fergiemcdowall/search-index/issues/278","id":214732256,"user":{"login":"fergiemcdowall","id":1122333,"avatar_url":"https://avatars.githubusercontent.com/u/1122333?v=3","gravatar_id":"","url":"https://api.github.com/users/fergiemcdowall","html_url":"https://github.com/fergiemcdowall","followers_url":"https://api.github.com/users/fergiemcdowall/followers","following_url":"https://api.github.com/users/fergiemcdowall/following{/other_user}","gists_url":"https://api.github.com/users/fergiemcdowall/gists{/gist_id}","starred_url":"https://api.github.com/users/fergiemcdowall/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fergiemcdowall/subscriptions","organizations_url":"https://api.github.com/users/fergiemcdowall/orgs","repos_url":"https://api.github.com/users/fergiemcdowall/repos","events_url":"https://api.github.com/users/fergiemcdowall/events{/privacy}","received_events_url":"https://api.github.com/users/fergiemcdowall/received_events","type":"User","site_admin":false},"created_at":"2016-04-26T12:57:10Z","updated_at":"2016-04-26T12:57:10Z","body":"@iSOcH hmmm- replicating from linux to windows _should_ work, since the export file is simply gzipped text. This is possibly an encoding issue.\r\n\r\nHave you tried examining the file on your windows machine? Is it readable?"}}