20.01.2015 Views

Performance Modeling and Benchmarking of Event-Based ... - DVS

Performance Modeling and Benchmarking of Event-Based ... - DVS

Performance Modeling and Benchmarking of Event-Based ... - DVS

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

46 CHAPTER 4. PERFORMANCE ENGINEERING OF EVENT-BASED SYSTEMS<br />

Pattern 2: St<strong>and</strong>ard Pub/Sub - Fixed Number <strong>of</strong> Subscribers<br />

1‘<strong>Event</strong>!<br />

" n‘Notification<br />

1‘<strong>Event</strong> 1‘<strong>Event</strong> 1‘Notification<br />

T2<br />

Create Notifications<br />

1‘Notification<br />

Producer<br />

T1<br />

Publish <strong>Event</strong><br />

Broker<br />

T3<br />

Forward <strong>Event</strong><br />

Consumers<br />

Transition 2<br />

In T2, for every incoming event n<br />

notifications are created.<br />

Broker<br />

<strong>Event</strong><br />

1<br />

n<br />

Broker<br />

Not.<br />

Figure 4.8: St<strong>and</strong>ard Pub/Sub Pattern - Fixed Number <strong>of</strong> Subscribers<br />

Characteristics<br />

• 1 : n communication (one event is consumed by n consumers)<br />

Example<br />

A fixed number <strong>of</strong> event consumers subscribe to a topic.<br />

Description<br />

A producer publishes an event, which is received by a broker. The broker notifies the event<br />

consumers (e.g. subscribers <strong>of</strong> a topic) by sending a notification event to them.<br />

The idea <strong>of</strong> this pattern is based on the presumption that the service dem<strong>and</strong> per event on<br />

the broker is composed <strong>of</strong> two parts, the service dem<strong>and</strong> needed for every incoming event <strong>and</strong><br />

the aggregated service dem<strong>and</strong>s for the notification <strong>of</strong> the subscribers:<br />

1‘Conf.No 1‘Conf.No<br />

S <strong>Event</strong>T otal,Broker = S <strong>Event</strong>,Broker + n · S Notification,Broker (4.19)<br />

Init T0 Controller T2‘<br />

where<br />

Configure Controlller<br />

Creates the configured no.<br />

n : No. <strong>of</strong> event notifications. <strong>of</strong> notifications per <strong>Event</strong>.<br />

S <strong>Event</strong>,Broker : Service dem<strong>and</strong> for receiving <strong>and</strong> processing incoming message.<br />

1‘<strong>Event</strong> 1‘<strong>Event</strong> 1‘Notification 1‘Notification<br />

S Notification,Broker : Service dem<strong>and</strong> <strong>of</strong> broker to create, process <strong>and</strong> send notifications.<br />

We implement the<br />

Producer<br />

T1 service dem<strong>and</strong> in our patterns by using two<br />

Broker<br />

T3 different token colors, one<br />

for the general service<br />

Consumers<br />

Publish costs <strong>Event</strong> (event) <strong>and</strong> one for the notifications Forward (notification) <strong>Event</strong> created by the<br />

broker. Therefore each incoming event is represented by one token event <strong>and</strong> n tokens <strong>of</strong> the<br />

color notification, where n is the number <strong>of</strong> consumers.<br />

In this version <strong>of</strong> the pattern, we implemented a straight-forward approach for a 1:n communication.<br />

The number <strong>of</strong> consumers is directly set in the cardinality <strong>of</strong> the transition (see Figure<br />

4.8). The downside <strong>of</strong> this approach is, that the number <strong>of</strong> consumers is fixed in the transition<br />

<strong>and</strong> therefore cannot be modified without changing the transition (<strong>and</strong> therefore the structure<br />

<strong>of</strong> the model). The reason is that cardinality <strong>of</strong> transitions in st<strong>and</strong>ard QPNs is defined as<br />

constant number. To add more flexibility we propose to allow not only constants but also, e.g.,<br />

distribution functions (see Section 4.3).

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!