Closed mdavidsaver closed 9 months ago
@zhouyunbin One simple way to issue two concurrent PUT operations.
using namespace pvxs;
client::Context ctxt(...);
auto op1(ctxt.put("pv1").set("value", 5).exec());
auto op2(ctxt.put("pv2").set("value", 6).exec());
op1->wait(5.0);
op2->wait(5.0);
This can be scaled by keeping a
https://github.com/mdavidsaver/pvxs/blob/dd2f076b4aa6dc63fb91980eda711eabee910696/tools/get.cpp#L104
The pvxget CLI also uses callbacks instead of multiple wait()
calls. This is done to allow the CLI to be interrupted cleanly by SIGINT
.
Copied from https://github.com/epics-base/pvAccessCPP/issues/188
I need to put lots of PV at the same time, which function I used is chan.put.set().exec(), but no matter how I use std::jthread or std::thread to achieve, it looks like always sequential execution at the bottom level. Is there a way to put the value without for waiting timeout?