Streaming Server - An Event Bus Implementation\
3:24 Big Notes on NATS Streaming
13:17 Building a NATS Test Project
20:49 Port-Forwarding with Kubectl
25:29 Publishing Events
31:50 Listening For Data
38:46 Accessing Event Data
45:42 Client ID Generation
50:30 Queue Groups
57:59 Manual Ack Mode
1:07:51 Client Health Checks
1:17:37 Graceful Client Shutdown
1:24:19 Core Concurrency Issues
1:37:15 Common Questions
1:45:24 [Optional] More Possible Concurrency Solutions
2:02:06 Solving Concurrency Issues
2:22:12 Concurrency Control with the Tickets App
2:31:53 Event Redelivery
2:36:28 Durable Subscriptions
to NATS in a Node JS World\
2:45:28 Reusable NATS Listeners
2:50:01 The Listener Abstract Class
2:59:28 Extending the Listener
3:05:22 Quick Refactor
3:08:40 Leveraging TypeScript for Listener Validation
3:14:08 Subjects Enum
3:17:38 Custom Event Interface
3:20:04 Enforcing Listener Subjects
3:27:27 Enforcing Data Types
3:31:21 Where Does this Get Used
3:34:10 Custom Publisher
3:42:22 Using the Custom Publisher
3:46:12 Awaiting Event Publication
3:50:41 Common Event Definitions Summary
3:57:07 Updating the Common Module
4:04:43 Restarting NATS
a NATS Client\
4:06:53 Publishing Ticket Creation
4:10:41 More on Publishing
4:14:01 NATS Client Singleton
4:19:25 Remember Mongoose
4:24:23 Singleton Implementation
4:33:28 Accessing the NATS Client
4:37:56 Graceful Shutdown
4:44:52 Successful Listen!
4:48:16 Ticket Update Publishing
4:52:44 Failed Event Publishing
4:59:47 Handling Publish Failures
5:05:50 Fixing a Few Tests
5:09:43 Redirecting Imports
5:15:18 Providing a Mock Implementation
5:24:27 Test-Suite Wide Mocks
5:26:40 Ensuring Mock Invocations
5:35:54 NATS Env Variables
Data Replication In Action\
5:43:55 The Orders Service
5:48:57 Scaffolding the Orders Service
5:53:37 A Touch More Setup
6:01:10 Ingress Routing Rules
6:03:04 Scaffolding a Few Route Handlers
6:12:59 Subtle Service Coupling
6:19:43 Associating Orders and Tickets
6:26:32 Order Model Setup
6:35:24 The Need for an Enum
6:41:21 Creating an Order Status Enum
6:49:53 More on Mongoose Refs
6:52:51 Defining the Ticket Model
7:00:01 Order Creation Logic
7:05:47 Finding Reserved Tickets
7:11:57 Convenience Document Methods
7:19:35 Order Expiration Times
7:25:40 Test Suite Setup
7:28:17 Asserting Tickets Exist
7:34:26 Asserting Reserved Tickets
7:39:31 Testing the Success Case
7:43:41 Fetching a User’s Orders
7:49:05 A Slightly Complicated Test
8:01:28 Fetching Individual Orders
8:06:05 Does Fetching Work
8:13:23 Cancelling an Order
8:17:55 Can We Cancel
Event Flow\
8:27:07 Orders Service Events
8:31:50 Creating the Events
8:41:14 Implementing the Publishers
8:44:27 Publishing the Order Creation
8:49:30 Publishing Order Cancellation
8:52:04 Testing Event Publishing
for Events and Handling Concurrency Issues\
8:57:37 Time for Listeners!
8:59:49 Reminder on Listeners
9:01:43 Blueprint for Listeners
9:05:23 A Few More Reminders
9:10:50 Simple onMessage Implementation
9:13:08 ID Adjustment
9:18:53 Ticket Updated Listener Implementation
9:23:25 Initializing the Listeners
9:26:10 A Quick Manual Test
9:29:27 Clear Concurrency Issues
9:42:26 Reminder on Versioning Records
9:49:07 Optimistic Concurrency Control
9:54:45 Mongoose Update-If-Current
9:58:32 Implementing OCC with Mongoose
10:02:34 Testing OCC
10:11:41 One More Test
10:15:27 Who Updates Versions
10:21:56 Including Versions in Events
10:24:56 Updating Tickets Event Definitions
10:28:52 Applying a Version Query
10:36:06 Did it Work
10:40:38 Abstracted Query Method
10:46:20 [Optional] Versioning Without Update-If-Current
11:04:55 Testing Listeners
11:09:51 A Complete Listener Test
11:19:16 Testing the Ack Call
11:21:25 Testing the Ticket Updated Listener
11:29:47 Success Case Testing
11:34:36 Out-Of-Order Events
11:39:28 The Next Few Videos
11:43:07 Fixing a Few Tests
11:49:44 Listeners in the Tickets Service
11:51:31 Building the Listener
11:56:31 Strategies for Locking a Ticket