time series - Using timestamp as mongodb _id? -
i want use mongodb store timeseries data, , think make things more sense keep 1 unique indexed field represent date-time. question is, can replace automatic _id
creation own timestamp, , there drawbacks?
can replace automatic _id creation own timestamp?
yes, can.
would there drawbacks?
one have work it, whereas built in _id is, well, built in. 1 you're responsible making sure _id indeed unique. depending on data frequency , kind of timestamp use, may or may not simple.
i'm not saying it's bad idea. advantages clear, but, yes, there drawbacks.
Comments
Post a Comment