mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-09 23:57:50 +01:00
Thread scheduling parameters: Use ZMQ context options instead of
environment variables.
This commit is contained in:
@@ -32,6 +32,7 @@
|
||||
#include "stdint.hpp"
|
||||
#include "options.hpp"
|
||||
#include "atomic_counter.hpp"
|
||||
#include "thread.hpp"
|
||||
|
||||
namespace zmq
|
||||
{
|
||||
@@ -87,6 +88,9 @@ namespace zmq
|
||||
zmq::socket_base_t *create_socket (int type_);
|
||||
void destroy_socket (zmq::socket_base_t *socket_);
|
||||
|
||||
// Start a new thread with proper scheduling parameters.
|
||||
void start_thread (thread_t &thread_, thread_fn *tfn_, void *arg_) const;
|
||||
|
||||
// Send command to the destination thread.
|
||||
void send_command (uint32_t tid_, const command_t &command_);
|
||||
|
||||
@@ -185,6 +189,10 @@ namespace zmq
|
||||
// Is IPv6 enabled on this context?
|
||||
bool ipv6;
|
||||
|
||||
// Thread scheduling parameters.
|
||||
int thread_priority;
|
||||
int thread_sched_policy;
|
||||
|
||||
// Synchronisation of access to context options.
|
||||
mutex_t opt_sync;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user