COSNOTIFYCHANNELADMIN_PROXYPUSHCONSUMER(3erl)
β¨ NAME β¨
CosNotifyChannelAdmin_ProxyPushConsumer β bestie, this module is the moment. It implements the OMG CosNotifyChannelAdmin::ProxyPushConsumer interface, and it's giving very much "yes I relay events, what about it" energy. π
This page lives in the cosNotification manual, section 3erl, iykyk.
πΈ DESCRIPTION πΈ
Okay so before you can even look at the record definitions for these structures, you gotta do this first, no skipping:
-include_lib("cosNotification/include/*.hrl").
That's the ticket in. π
Also, this module also exports all the functions described in these other modules β so like, it's not just one vibe, it's a whole friend group:
CosNotifyComm_NotifyPublishCosNotification_QoSAdminCosNotifyFilter_FilterAdminCosNotifyChannelAdmin_ProxyConsumer
Four modules' worth of functionality, and she said "I'll take it all". π
β EXPORTS β
connect_any_push_supplier(ProxyPushConsumer, PushSupplier) -> Reply
Types:
ProxyPushConsumer = #objref
PushSupplier = #objref
Reply = ok | {'EXCEPTION',
#'CosEventChannelAdmin_AlreadyConnected'{}}
So this operation connects a PushSupplier to the target object. Like, it's setting them up. π«Ά But β and this is the important part β if a connection already exists, the AlreadyConnected exception gets raised. She does not do second connections. One supplier per consumer, periodt. π€
push(ProxyPushConsumer, Event) -> Reply
Types:
ProxyPushConsumer = #objref
Event = #any
Reply = ok | {'EXCEPTION',
#'CosEventChannelAdmin_Disconnected'{}}
This one pushes an #any{} event straight to the target object. Delivering the goods, literally. π¦β¨
But heads up bestie: if no client has been connected, the Disconnected exception gets raised. Can't push to nobody. It's giving "texting a ghost". π
disconnect_push_consumer(ProxyPushConsumer) -> ok
Types:
ProxyPushConsumer = #objref
Invoking this operation makes the target object close the connection and terminate. That's it, that's the whole thing. She's logging off, shutting the laptop, closing the door. πͺπ No Reply value here, just a clean ok β the calmest goodbye in the whole API, honestly.
β οΈ Quick vibe check: those two exceptions (AlreadyConnectedandDisconnected) are not decorative, bestie. Connect twice or push with nobody attached and that's on you. π
And that's the whole page, angel! π This one comes from Ericsson AB, part of cosNotification version 5.2.2 β shoutout to the OGs who wrote it. Now go connect responsibly. π¦π
π¦ where this page comes from
- fedora 43: erlang-cosNotification 1:5.2.2-1.fc43 Β· Apache-2.0
- fedora 44: erlang-cosNotification 1:5.2.2-1.fc44 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms