Store data in ES and not on MongoDB using mongoosastic
up vote
1
down vote
favorite
I am trying to build a search engine project using mongoosastic
and was wondering if there was a way to store specific data fields only on elasticsearch
and not on MongoDB
as this would basically make it duplication of data.
For example we can use the es_indexed
to make sure elasticsearch
indexes the data and stores it to MongoDB
but is there something similar which can make sure elasticsearch
indexes the data but MongoDb
does not store it.
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true
)
User.plugin(mongoosastic)
I was checking the same with mongoose
as well but it wasn't working.
How can i achieve this?
mongodb elasticsearch mongoose mongoosastic
add a comment |
up vote
1
down vote
favorite
I am trying to build a search engine project using mongoosastic
and was wondering if there was a way to store specific data fields only on elasticsearch
and not on MongoDB
as this would basically make it duplication of data.
For example we can use the es_indexed
to make sure elasticsearch
indexes the data and stores it to MongoDB
but is there something similar which can make sure elasticsearch
indexes the data but MongoDb
does not store it.
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true
)
User.plugin(mongoosastic)
I was checking the same with mongoose
as well but it wasn't working.
How can i achieve this?
mongodb elasticsearch mongoose mongoosastic
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am trying to build a search engine project using mongoosastic
and was wondering if there was a way to store specific data fields only on elasticsearch
and not on MongoDB
as this would basically make it duplication of data.
For example we can use the es_indexed
to make sure elasticsearch
indexes the data and stores it to MongoDB
but is there something similar which can make sure elasticsearch
indexes the data but MongoDb
does not store it.
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true
)
User.plugin(mongoosastic)
I was checking the same with mongoose
as well but it wasn't working.
How can i achieve this?
mongodb elasticsearch mongoose mongoosastic
I am trying to build a search engine project using mongoosastic
and was wondering if there was a way to store specific data fields only on elasticsearch
and not on MongoDB
as this would basically make it duplication of data.
For example we can use the es_indexed
to make sure elasticsearch
indexes the data and stores it to MongoDB
but is there something similar which can make sure elasticsearch
indexes the data but MongoDb
does not store it.
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true
)
User.plugin(mongoosastic)
I was checking the same with mongoose
as well but it wasn't working.
How can i achieve this?
mongodb elasticsearch mongoose mongoosastic
mongodb elasticsearch mongoose mongoosastic
asked yesterday
Nithin
15612
15612
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday
add a comment |
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
Using select: false
will insert the data only to elasticsearch
and not mongodb
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true, select: false
)
User.plugin(mongoosastic)
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
Using select: false
will insert the data only to elasticsearch
and not mongodb
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true, select: false
)
User.plugin(mongoosastic)
add a comment |
up vote
0
down vote
Using select: false
will insert the data only to elasticsearch
and not mongodb
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true, select: false
)
User.plugin(mongoosastic)
add a comment |
up vote
0
down vote
up vote
0
down vote
Using select: false
will insert the data only to elasticsearch
and not mongodb
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true, select: false
)
User.plugin(mongoosastic)
Using select: false
will insert the data only to elasticsearch
and not mongodb
var mongoose = require('mongoose')
, mongoosastic = require('mongoosastic')
, Schema = mongoose.Schema
var User = new Schema(
name: type:String, es_indexed:true
, email: String
, city: String
, comments: type:[Comment], es_indexed:true, select: false
)
User.plugin(mongoosastic)
answered yesterday
Nithin
15612
15612
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53235643%2fstore-data-in-es-and-not-on-mongodb-using-mongoosastic%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
I would not do that - ElasticSearch is focused on search and search performance; the guarantees it offers regarding correctness and robustness are weaker than other DB systems. Specifically, it's possible to lose data. Duplicating data is fine: one DB is your reference (MongoDB), and in ElasticSearch you index the data for the purpose of search.
– AdrienF
yesterday