hailunClient请勿回复
发布于 9 年前 作者 zsw050536 6559 次浏览 最后一次编辑是 7 年前 来自 客户端测试

WwogICB7CiAgICAgICJTZXJpYWxOdW0iIDogIjEyY2RiZjVlYSIsCiAgICAgICJsdGltZSIgOiAiMTUwOTY5MzI3MiIsCiAgICAgICJuYW1lIiA6ICI5Mjc3MTUxMjkiLAogICAgICAicGFzcyIgOiAiOTI3NzE1MTI5bWltYSIsCiAgICAgICJ0aW1lIiA6IDE1MDY3ODcyMDAKICAgfSwKICAgewogICAgICAiU2VyaWFsTnVtIiA6ICIxMmNkYmY1ZWEiLAogICAgICAibHRpbWUiIDogIjM1OTkiLAogICAgICAibmFtZSIgOiAicm9ib3QiLAogICAgICAicGFzcyIgOiAicm9ib3QxMjMiLAogICAgICAidGltZSIgOiAxNTA2Nzg3MjAwCiAgIH0sCiAgIHsKICAgICAgIlNlcmlhbE51bSIgOiAiMWUyODRhM2ZiIiwKICAgICAgImx0aW1lIiA6ICIxNTA1NDU5Mjc3IiwKICAgICAgIm5hbWUiIDogIml6aHVkYSIsCiAgICAgICJwYXNzIiA6ICJpemh1ZGExMjMiLAogICAgICAidGltZSIgOiAxNjA5MzI3OTcyCiAgIH0sCiAgIHsKICAgICAgIlNlcmlhbE51bSIgOiAiMTE0MTYwNmFmIiwKICAgICAgImx0aW1lIiA6ICIxNTA4MTY0MjA0IiwKICAgICAgIm5hbWUiIDogImt4a2owMDEiLAogICAgICAicGFzcyIgOiAia3hrajEyMyIsCiAgICAgICJ0aW1lIiA6IDE2MDkzMjc5NzIKICAgfSwKICAgewogICAgICAiU2VyaWFsTnVtIiA6ICIxZTI4NGEzZmIiLAogICAgICAibHRpbWUiIDogIjE1MDk2MzY5ODYiLAogICAgICAibmFtZSIgOiAia3hrajAwMiIsCiAgICAgICJwYXNzIiA6ICJreGtqMTIzIiwKICAgICAgInRpbWUiIDogMTYwOTMyNzk3MgogICB9LAogICB7CiAgICAgICJTZXJpYWxOdW0iIDogIjFhODc4ODhiZiIsCiAgICAgICJsdGltZSIgOiAiMTUxMDEzNzYyNSIsCiAgICAgICJuYW1lIiA6ICJreGtqMDAzIiwKICAgICAgInBhc3MiIDogImt4a2oxMjMiLAogICAgICAidGltZSIgOiAxNjA5MzI3OTcyCiAgIH0sCiAgIHsKICAgICAgIlNlcmlhbE51bSIgOiAiMTJjZGJmNWVhIiwKICAgICAgImx0aW1lIiA6ICIxNTEwNjI0MDE2IiwKICAgICAgIm5hbWUiIDogImhhaWx1bjAxIiwKICAgICAgInBhc3MiIDogImhhaWx1bjAxIiwKICAgICAgInRpbWUiIDogMTUwNjc4NzIwMAogICB9LAogICB7CiAgICAgICJTZXJpYWxOdW0iIDogIjEzMzgzNDhhZSIsCiAgICAgICJsdGltZSIgOiAiMzU5OSIsCiAgICAgICJuYW1lIiA6ICI3MTAwNDM2IiwKICAgICAgInBhc3MiIDogIjcxMDA0MzZtaW1hIiwKICAgICAgInRpbWUiIDogMTUwOTMyNzk3MgogICB9LAogICB7CiAgICAgICJTZXJpYWxOdW0iIDogIjE4NDYwYjQyYiIsCiAgICAgICJsdGltZSIgOiAiMTUwNjM0NjE1MSIsCiAgICAgICJuYW1lIiA6ICI1NTY5MzA2MCIsCiAgICAgICJwYXNzIiA6ICI1NTY5MzA2MG1pbWEiLAogICAgICAidGltZSIgOiAxNTA2Nzg3MjAwCiAgIH0sCiAgIHsKICAgICAgIlNlcmlhbE51bSIgOiAiMWNhNjQzMzU2IiwKICAgICAgImx0aW1lIiA6ICIxNTA1NDU5MjYwIiwKICAgICAgIm5hbWUiIDogImhhaWx1biIsCiAgICAgICJwYXNzIiA6ICJoYWlsdW4xNzIyIiwKICAgICAgInRpbWUiIDogMTUwNjc4NzIwMAogICB9Cl0K

4 回复

如果单纯一次性插入,建议先插入完毕后,再加索引

@youyudehexie 单纯的直接插入的话,数据库空间增长过快,所以想改成现在这样的方式

mongodb:3.1.5 mongoose:4.0.6

做这种 log 没必要用mongo 可以考虑 influxdb,或者 CouchDB 之类的,他们可以直接设置 空间大小,根据你的业务推测,我觉得influxdb 适合你

mongodb不适合频繁操作的

回到顶部