Zeromq interface function: ZMQ_IPC–ZMQ local interprocess communication Transfer Protocol

Source: Internet
Author: User
Tags creative commons attribution

ZeroMQ API directory :http://www.cnblogs.com/fengbohello/p/4230135.html

—————————————————————————————————————

ZeroMQ official address:HTTP://API.ZEROMQ.ORG/3-2:ZMQ-IPC

ZMQ_IPC (7) ØMQ Manual-ømq/3.2.5

Name

ZMQ_IPC–ZMQ local inter-process communication Transfer Protocol

Synopsis

Inter-process transport uses a system-related IPC mechanism for message communication between local processes.

The inter-process transfer method is now fully implemented on the socket system that provides the UNIX definition.

Addressing

An endpoint includes transport:// followed by an address (for IPC, ipc://address). The transport specifies the underlying system protocol to use. address specifies the specified addresses that need to be connected.

For inter-process transmission, transport refers to the IPC, the address section is defined below.

Bind a socket

When using the Zmq_bind () function to bind a local socket with an IPC transfer, the endpoint should be a file name of any string that uniquely flags the file that will be created. The file name should be the only one in the operating system namespace that operates using IPC. This file name must also meet the operating system's limitations on the format and length of the normal file name.

When the address is *, the zmq_bind () function generates a temporary file name. The caller needs to get this file name using the Zmq_last_endpoint property. See the Zmq_getsockopt (3) function for more details.

All actions that are bound to a file name that already exists will be overloaded. In this case, the IPC protocol is not the same as the TCP or InProc protocol.

Connect a socket

When using the Zmq_connect () function to initiate an IPC connection to a peer, the endpoint needs to be an arbitrary string that uniquely flags a file name. This file name must have been created by the operating system and assigned to a socket that has been manipulated through Zmq_bind ().

Examples

  Assign an address to a socket

//   Assign The pathname "/tmp/feeds/0" "ipc:///tmp/feeds/0"   0);

  Connect a socket

// Connect to the   pathname "/tmp/feeds/0""ipc:///tmp/feeds/0"0 );

See Also

Zmq_bind (3) zmq_connect (3) Zmq_inproc (7) zmq_tcp (7) ZMQ_PGM (7) zmq_getsockopt (3) ZMQ (7)

Authors

THISØMQ manual page was written by Pieter Hintjens <[email protected]>, Martin Sustrik <[email protected]> an D Martin Lucina <[email protected]>.

WEB site design and content is copyright (c) 2007-2012 Imatix Corporation. Contact us for professional support. Site content licensed under the Creative Commons attribution-share alike 3.0 License. ØMQ is copyright (c) Copyright (c) 2007-2012 Imatix Corporation and Contributors. ØMQ is free software licensed under the LGPL. ØMQ, ZeroMQ, and 0MQ are trademarks of Imatix Corporation. Terms of Use-privacy

Policy

Translation: The Storm

Mail: [Email protected]

Zeromq interface function: ZMQ_IPC–ZMQ local interprocess communication Transfer Protocol

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.