وبلاگ بلیان

Learn Microservices with Spring Boot : A Practical Approach to RESTful Services Using RabbitMQ, Eureka, Ribbon, Zuul and Cucumber

معرفی کتاب «Learn Microservices with Spring Boot : A Practical Approach to RESTful Services Using RabbitMQ, Eureka, Ribbon, Zuul and Cucumber» نوشتهٔ Moises Macero (auth.)، منتشرشده توسط نشر Apress : Imprint: Apress در سال 2017. این کتاب در 3 صفحه، فرمت pdf، زبان انگلیسی ارائه شده است.

Build a microservices architecture with Spring Boot, by evolving an application from a small monolith to an event-driven architecture composed of several services. This book follows an incremental approach to teach microservice structure, test-driven development, Eureka, Ribbon, Zuul, and end-to-end tests with Cucumber.Author Moises Macero follows a very pragmatic approach to explain the benefits of using this type of software architecture, instead of keeping you distracted with theoretical concepts. He covers some of the state-of-the-art techniques in computer programming, from a practical point of view. You’ll focus on what's important, starting with the minimum viable product but keeping the flexibility to evolve it.**What You'll Learn** * Build microservices with Spring Boot * Use event-driven architecture and messaging with RabbitMQ * Create RESTful services with Spring * Master service discovery with Eureka and load balancing with Ribbon * Route requests with Zuul as your API gateway * Write end-to-end rests for an event-driven architecture using Cucumber * Carry out continuous integration and deployment **Who This Book Is For**Those with at least some prior experience with Java programming. Some prior exposure to Spring Boot recommended but not required. Table of Contents 4 About the Author 10 About the Technical Reviewer 11 Chapter 1: Introduction 12 Setting the Scene 12 Who Are You? 13 How Is This Book Different from Other Books and Guides? 14 Reasoning Behind the Techniques 14 Learning: An Incremental Process 15 Is This a Guide or a Book? 15 Contents 16 From the Basics to Advanced Topics 16 Skeleton with Spring Boot, the Professional Way 16 Test-Driven Development 17 Connecting Microservices 17 Event-Driven System 17 End-to-End Testing 18 Summary 18 Chapter 2: The Basic Spring Boot Application 19 Business Requirements 19 The Skeleton App 20 Skinny vs. Real-Life Apps 20 Creating the Skeleton 21 Warming Up: Some TDD in Action 23 Summary 31 Chapter 3: A Real Three-Tier Spring Boot Application 32 Introduction 32 Completing the Basics 35 Designing the Domain 42 The Business Logic Layer 47 The Presentation Layer (REST API) 50 The Multiplication Controller 52 The Results Controller 57 The Frontend (Web Client) 62 Playing with the Application (Part I) 67 New Requirements for Data Persistence 68 Refactoring the Code 72 The Data Layer 77 The Data Model 80 The Repositories 86 Completing User Story 2: Going Through the Layers 96 Playing with the Application (Part II) 103 Summary 106 Chapter 4: Starting with Microservices 108 The Small Monolith Approach 108 Analyzing the Monolith 112 Moving Forward 114 Gamification Basics 115 Points, Badges, and Leaderboards 115 Applying It to the Example 116 Moving to a Microservices Architecture 117 Separation of Concerns and Loose Coupling 117 Independent Changes 118 Scalability 118 Connecting Microservices 119 Event-Driven Architecture 121 Related Techniques 122 Pros and Cons of Event-Driven Architecture 123 Loose Coupling 124 Transactions 124 Fault Tolerance 125 Orchestration and Monitoring 125 Evaluate Before Making a Decision 126 Further Reading 126 Applying Event-Driven Architecture to the Application 127 Going Event-Driven with RabbitMQ and Spring AMQP 128 Using RabbitMQ in Your System 129 Spring AMQP 130 Sending Events from Multiplication 130 RabbitMQ Configuration 131 Modeling the Event 134 Sending the Event: Dispatcher Pattern 137 Deeper Look at the New Gamification Microservice 143 Code Overview 143 The Domain 144 The Data 150 The Business Logic 153 The REST API (Controllers) 160 Receiving Events with RabbitMQ 163 The Subscriber’s Side 163 RabbitMQ Configuration 163 The Event Handler 166 Requesting Data Between Microservices 169 Combining Reactive Patterns and REST 169 Keeping Domains Isolated 171 Implementing the REST Client 174 Updating Gamification’s Business Logic 179 Playing with the Microservices 182 Summary 185 Chapter 5: The Microservices Journey Through Tools 187 Introduction 187 Extracting the UI and Connecting It to Gamification 188 Moving the Static Content 190 Connecting UI with Gamification 192 Changes to Existing Services 195 A New, Better UI with (Almost) No Effort 198 The Current Architecture 208 Service Discovery and Load Balancing 210 Service Discovery 210 Load Balancing 213 Polyglot Systems, Eureka, and Ribbon 215 Routing with an API Gateway 217 The API Gateway Pattern 217 Zuul, Eureka, and Ribbon Working Together 222 Hands-On Code 226 Implementing the API Gateway with Zuul 226 Implementing Service Discovery 234 Playing with Service Discovery 245 Are Our Microservices Ready to Scale? 249 Databases and Stateless Services 249 Event-Driven Architecture and Load Balancing 250 Load Balancing with Ribbon 252 Playing with Load Balancing 254 Fine-Tuning the Load Balancing Strategy 257 Circuit Breakers and REST Clients 262 Circuit Breakers with Hystrix 262 Hystrix and Zuul 263 Hystrix from a REST Client 266 REST Consumers with Feign 269 Microservices Patterns and PaaS 271 Summary 272 Chapter 6: Testing the Distributed System 274 Introduction 274 Setting the Scene 276 How Cucumber Works 278 Hands-On Code 280 Creating an Empty Project and Choosing the Tools 281 Making the System Testable 285 New API Interfaces 286 Test Profiles 288 Handling Test Data 290 Writing the First Cucumber Test 294 Linking a Feature to Java Code 298 The Supporting Classes 309 Reusing Steps Across Features 315 Running Tests and Checking Reports 318 Summary 321 Appendix A: Upgrading to Spring Boot 2.0 322 Introduction 322 Upgrading the Dependencies 323 Fixing the Breaking Changes 326 The CrudRepository Interface Does Not Include findOne() 326 Actuator Endpoints Have Been Moved 327 Applying Optional Updates 328 The WebMvcConfigurerAdapter Class Has Been Deprecated 328 Working with Spring Boot 2.0 329 Afterword 330 Index 332 Build a microservices architecture with Spring Boot, by evolving an application from a small monolith to an event-driven architecture composed of several services. This book follows an incremental approach to teach microservice structure, test-driven development, Eureka, Ribbon, Zuul, and end-to-end tests with Cucumber. Author Moises Macero follows a very pragmatic approach to explain the benefits of using this type of software architecture, instead of keeping you distracted with theoretical concepts. He covers some of the state-of-the-art techniques in computer programming, from a practical point of view. You’ll focus on what's important, starting with the minimum viable product but keeping the flexibility to evolve it. What You'll Learn Build microservices with Spring Boot Use event-driven architecture and messaging with RabbitMQ Create RESTful services with Spring Master service discovery with Eureka and load balancing with Ribbon Route requests with Zuul as your API gateway Write end-to-end rests for an event-driven architecture using Cucumber Carry out continuous integration and deployment Who This Book Is For Those with at least some prior experience with Java programming. Some prior exposure to Spring Boot recommended but not required. Build a microservices architecture with Spring Boot, by evolving an application from a small monolith to an event-driven architecture composed of several services. This book follows an incremental approach to teach microservice structure, test-driven development, Eureka, Ribbon, Zuul, and end-to-end tests with Cucumber. Author Moises Macero follows a very pragmatic approach to explain the benefits of using this type of software architecture, instead of keeping you distracted with theoretical concepts. He covers some of the state-of-the-art techniques in computer programming, from a practical point of view. You?ll focus on what's important, starting with the minimum viable product but keeping the flexibility to evolve it. You will: Build microservices with Spring Boot Use event-driven architecture and messaging with RabbitMQ Create RESTful services with Spring Master service discovery with Eureka and load balancing with Ribbon Route requests with Zuul as your API gateway Write end-to-end rests for an event-driven architecture using Cucumber Carry out continuous integration and deployment Front Matter ....Pages i-xi Introduction (Moises Macero)....Pages 1-7 The Basic Spring Boot Application (Moises Macero)....Pages 9-21 A Real Three-Tier Spring Boot Application (Moises Macero)....Pages 23-98 Starting with Microservices (Moises Macero)....Pages 99-177 The Microservices Journey Through Tools (Moises Macero)....Pages 179-265 Testing the Distributed System (Moises Macero)....Pages 267-314 Back Matter ....Pages 315-330
دانلود کتاب Learn Microservices with Spring Boot : A Practical Approach to RESTful Services Using RabbitMQ, Eureka, Ribbon, Zuul and Cucumber