Questions tagged [event-driven]

The event-driven paradigm of programming centralizes all waiting for events to one generalized loop that delivers (dispatches) events to registered listeners (event handlers).

The event-driven paradigm of programming centralizes all waiting for events to one generalized loop that delivers (dispatches) events to registered listeners (event handlers). When triggered, the event handlers change the state of the program, sometimes even by de-registering event handlers.

418 questions
6
votes
2 answers

RabbitMQ and Sails.js

I'm having trouble using RabbitMQ with my Sails app. I'm unsure of where to place the subscriber code. What I'm trying to do is build a notifications system so that when an administrator approves a user's data request, the user's dashboard will pop…
kk415kk
  • 1,227
  • 1
  • 14
  • 30
6
votes
1 answer

Creating a simple event driven architecture

Having a bit of trouble with a project at the moment. I am implementing a game and I'd like to have it event-driven. So far I have an EventHandler class which has an overloaded method depending on what type of event is generated(PlayerMove, Contact,…
LiamRyan
  • 1,892
  • 4
  • 32
  • 61
6
votes
1 answer

What is event-driven programming?

What is event-driven programming and has event-driven programming anything to do with threading? I came to this question reading about servers and how they handle user requests and manage data. If user sends request, server begins to process data…
omegasbk
  • 826
  • 1
  • 10
  • 24
5
votes
3 answers

Expression Blend VSM vs Event Driven

I recently used Expression Blend and I found that it has something called Visual State Manager, what is the difference between it and the regular event driven model, and which is better?
5
votes
2 answers

Can a domain event be emitted without being part of an aggregate state change (DDD)

I would like to know how can a domain event be implemented (in DDD) if it is not a natural result of an aggregate's state change. I will borrow the example of this post. So lets say that we need an event like: temperatureWasMeasured which could be a…
5
votes
1 answer

google cloud pub sub multiple subscriber for the same message with the same subscription

I am working on implementing event driven using GCP Pub/Sub. I have a topic called orders, and that topic will have a subscription named orderPlacedSubscription I have two services that want to listen to all messages for this subscription and…
5
votes
2 answers

Can WebAssembly get javascript callback?

Is it possible to pass javascript callback to WebAssembly? Can we trigger an event from WebAssembly and listen to it in javascript?
Shula
  • 167
  • 1
  • 18
5
votes
0 answers

Event-driven design with callbacks in Rust

I'd like to know how a composable event-driven design with callbacks can be used in Rust. From my existing experimentation, I have come to suspect that the ownership system in Rust is more suited to top-down procedural code and has problems with…
Ambroz Bizjak
  • 7,809
  • 1
  • 38
  • 49
5
votes
3 answers

Asynchronous I/O - Java

I have been searching for details on the advantages of asynchronous I/O in Java, particularly from the application stack designing. I encountered numerous examples of event driven servers like Node.js, Tornedo etc. What I failed to understand is why…
Suraj
  • 132
  • 1
  • 1
  • 9
4
votes
3 answers

Event Based == Asynchronous?

Is "event based" the same as "asynchronous"?
nickb
  • 9,140
  • 11
  • 39
  • 48
4
votes
0 answers

Domain Events vs Event notification vs Event-carried state transfer ECST in event driven architecture, implementing Domain Driven Design (DDD)

I would like to clarify in my mind the way different kinds of events could be implemented in a EDA system (system with Event Driven Architecture) implementing DDD (Domain Driven Design). Let assume that we are not using event sourcing. More…
4
votes
1 answer

What are the strategies for payload in an event-driven architecture

I want to know that further details about payloads in an event-driven architecture. I used several online resources and didn't get many details. Please help me to find, Use of the Full Payload. Provide Metadata and an API link with a token to…
User_1000
  • 65
  • 1
  • 8
4
votes
2 answers

How does event-driven programming help a webserver that only does IO?

I'm considering a few frameworks/programming methods for our new backend project. It regards a BackendForFrontend implementation, which aggregates downstream services. For simplicity, these are the steps it goes trough: Request comes into the…
4
votes
1 answer

How socket.io works

I would like to know how socket.io methods work for emitting a certain event, I've read that it is not like long-polling method but a different one that can work on all of different browsers ... How could a client keep-in-contact with the server…
pippo
  • 774
  • 6
  • 10
4
votes
2 answers

how to use AnyEvent::Handler with socket that has port reuse

Recently I ran into a great perl module "AnyEvent", which allows user to do asynchronous/event-driven programing. Created the following snippet which works fine. The problem I have is that after it opens and closes lots sockets, it quickly exhausted…
pktCoder
  • 1,105
  • 2
  • 15
  • 32