Open jingyuLin1999 opened 3 years ago
could support function* worker
const mqQueue = require('fastq')({ select, fork }, worker, 1); eventbus.on(configs.topic_tools_status + configs.factoryCode + '_' + configs.shopCode.toLocaleUpperCase(), (msg) => { if (msg.Type_Data == 101 || msg.Type_Data == 106) mqQueue.push(msg) }) function* worker(arg, cb) { let bbb = this.select((state) => { return state.tools3Test }); console.log(bbb) // yield put({ type: "consumerQueue", payload: { arg, cb } }) cb(null, arg) }
I'm a bit lost on who will receive the data that is going to be yielded.
could support function* worker