1
我想設置一個簡單的物聯網溫度監測系統。 Node Red似乎是一個很好的解決方案。節點紅色的MongoDB限制需要一個整數
我已經在Ubuntu 16.04上安裝了node red和mongodb。當我嘗試將數據存儲到MongoDB中,會儲存succesfulyy,然而,當我試圖從我的數據庫獲取數據,讓我的調試選項卡上的以下錯誤:MongoError: limit requires an integer
這裏是我的節點:
[{"id":"845a2d0f.f529f","type":"debug","z":"175fe64a.2e87ba","name":"","active":true,"console":"false","complete":"false","x":698,"y":118,"wires":[]},{"id":"37b967b4.5953a8","type":"http in","z":"175fe64a.2e87ba","name":"/iot request","url":"/iot","method":"get","swaggerDoc":"","x":229.9517059326172,"y":314.0511169433594,"wires":[["70d77b6c.c2f234"]]},{"id":"70d77b6c.c2f234","type":"mongodb in","z":"175fe64a.2e87ba","mongodb":"5b5bee5b.f2593","name":"retrieve hello","collection":"test","operation":"find","x":472.9545593261719,"y":356.5880432128906,"wires":[["3b3c5324.f2f78c"]]},{"id":"3b3c5324.f2f78c","type":"http response","z":"175fe64a.2e87ba","name":"show hello","x":760.960205078125,"y":311.91192626953125,"wires":[]},{"id":"ac92efad.22272","type":"mqtt in","z":"175fe64a.2e87ba","name":"get outtemp","topic":"/sensors/esp0/temp0","qos":"2","broker":"fd4c9ee3.0aa1a","x":193,"y":118,"wires":[["845a2d0f.f529f","63a9e917.39f568"]]},{"id":"63a9e917.39f568","type":"mongodb out","z":"175fe64a.2e87ba","mongodb":"5b5bee5b.f2593","name":"store temp","collection":"test","payonly":true,"upsert":false,"multi":false,"operation":"store","x":406,"y":219,"wires":[]},{"id":"5b5bee5b.f2593","type":"mongodb","z":"","hostname":"127.0.0.1","port":"27017","db":"testdb","name":""},{"id":"fd4c9ee3.0aa1a","type":"mqtt-broker","z":"","broker":"localhost","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"200","cleansession":true,"willTopic":"","willQos":"0","willPayload":"","birthTopic":"","birthQos":"0","birthPayload":""}]
我是一個完整的begginer,兩個節點都是紅色的mongodb,有一些mqtt的經驗。
我該如何解決這個問題?
我認爲這個問題已經修復了最新版本的mongo節點 - 紅色節點。而不是嘗試在評論中對它進行調試,你可以發佈在node-red郵件列表上(nodered.org底部的鏈接) – knolleary
@knolleary感謝提示,還有另外一個人有同樣的問題郵件列表(這沒有顯示在我的谷歌搜索);問題解決了 –