Slide 62
Slide 62 text
イベントとステート- Pull QueryとPush Query
Seven
Eleven
payment: 500 JPY
CREATE STREAM payments AS
SELECT
Account_id,
store,
amount
FROM transactions
EMIT CHANGES;
CREATE TABLE payment_sum AS
SELECT
account_id,
SUM (amount)
FROM transactions
GROUP BY account_id
TUMBLING WINDOW (1 DAY)
EMIT CHANGES;
Yoshinoya
payment: 800 JPY
AEON
payment: 2,400
JPY
hashi: 3700 JPY
PULL
hashi: Seven Eleven, 500 JPY
hashi: Yoshinoya, 800 JPY
hashi: AEON, 2400 JPY
PUSH
hashi: 500 JPY
hashi: 1300 JPY
hashi: 3700 JPY
PUSH