IPCQUEUE(1)
π IPCQUEUE(1) π
okay bestie, welcome to ipcqueue(1) β the manual page for ipcqueue π pull up a chair, we're doing queues today and honestly? iconic.
β¨ NAME β¨
ipcqueue β literally the ipcqueue Documentation. that's it, that's the name, short and sweet π
π¦ POSIX MESSAGE QUEUE π¦
okay so first up: the POSIX flavour. here's the whole vibe, no cap π«Ά
>>> from ipcqueue import posixmq
>>> q = posixmq.Queue('/foo')
>>> q.qsize()
0
>>> q.put([1, 'A'])
>>> q.put([2, 'B'], priority=2)
>>> q.put([3, 'C'], priority=0)
>>> q.qsize()
3
>>> q.get()
[2, 'B']
>>> q.get()
[1, 'A']
>>> q.get()
[3, 'C']
>>> q.close()
>>> q.unlink()
so you import posixmq, you spin up a Queue on '/foo', and qsize() is like... 0 at first. then three puts go in with different priority values, qsize() says 3, and the gets come out in that order: [2, 'B'], [1, 'A'], [3, 'C'] β¨ and then β the important part β q.close() and q.unlink(). don't forget the cleanup bestie, we're not leaving mess behind π§Ήπ
π SYS V MESSAGE QUEUE π
now the other one, the SYS V one. she's giving legacy-but-thriving energy π
>>> from ipcqueue import sysvmq
>>> q = sysvmq.Queue(1)
>>> q.qsize()
>>> q.put([1, 'A'])
>>> q.put([2, 'B'], msg_type=2)
>>> q.put([3, 'C'], msg_type=2)
>>> q.put([4, 'D'], msg_type=1)
>>> q.qsize()
4
>>> q.get(msg_type=2)
[2, 'B']
>>> q.get()
[1, 'A']
>>> q.get()
[3, 'C']
>>> q.get()
[4, 'D']
>>> q.close()
this time it's sysvmq and the Queue takes 1 β that's the key, not a path, different girl different vibe π. note that here msg_type is the thing you pass to put, and q.qsize() comes back 4 after all four puts. then q.get(msg_type=2) pulls [2, 'B'], and the rest fall out in order: [1, 'A'], [3, 'C'], [4, 'D'] π₯ and yeah, q.close() at the end, periodt.
π AUTHOR π
Jan Seifert β the author, the icon, the moment π«Ά
π COPYRIGHT π
2017, Jan Seifert. all the rights, all the credit, as it should be β¨
okay that's the whole page bestie!! this was the ipcqueue manual, Oct 05, 2025 edition β that's the source and the date, so you know exactly which one you're reading π
π now go forth and queue responsibly, mwah π
π
π¦ where this page comes from
- fedora 43: python3-ipcqueue 0.9.7-6.fc43 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms