Spring Cloud


Table of Contents

1. Features
I. Cloud Native Applications
2. Spring Cloud Context: Application Context Services
2.1. The Bootstrap Application Context
2.2. Application Context Hierarchies
2.3. Changing the Location of Bootstrap Properties
2.4. Overriding the Values of Remote Properties
2.5. Customizing the Bootstrap Configuration
2.6. Customizing the Bootstrap Property Sources
2.7. Logging Configuration
2.8. Environment Changes
2.9. Refresh Scope
2.10. Encryption and Decryption
2.11. Endpoints
3. Spring Cloud Commons: Common Abstractions
3.1. @EnableDiscoveryClient
3.1.1. Health Indicator
3.1.2. Ordering DiscoveryClient instances
3.2. ServiceRegistry
3.2.1. ServiceRegistry Auto-Registration
ServiceRegistry Auto-Registration Events
3.2.2. Service Registry Actuator Endpoint
3.3. Spring RestTemplate as a Load Balancer Client
3.4. Spring WebClient as a Load Balancer Client
3.4.1. Retrying Failed Requests
3.5. Multiple RestTemplate objects
3.6. Spring WebFlux WebClient as a Load Balancer Client
3.7. Ignore Network Interfaces
3.8. HTTP Client Factories
3.9. Enabled Features
3.9.1. Feature types
3.9.2. Declaring features
3.10. Spring Cloud Compatibility Verification
II. Spring Cloud Config
4. Quick Start
4.1. Client Side Usage
5. Spring Cloud Config Server
5.1. Environment Repository
5.1.1. Git Backend
Skipping SSL Certificate Validation
Setting HTTP Connection Timeout
Placeholders in Git URI
Pattern Matching and Multiple Repositories
Authentication
Authentication with AWS CodeCommit
Git SSH configuration using properties
Placeholders in Git Search Paths
Force pull in Git Repositories
Deleting untracked branches in Git Repositories
Git Refresh Rate
5.1.2. Version Control Backend Filesystem Use
5.1.3. File System Backend
5.1.4. Vault Backend
Multiple Properties Sources
5.1.5. Accessing Backends Through a Proxy
5.1.6. Sharing Configuration With All Applications
File Based Repositories
Vault Server
5.1.7. JDBC Backend
5.1.8. Composite Environment Repositories
Custom Composite Environment Repositories
5.1.9. Property Overrides
5.2. Health Indicator
5.3. Security
5.4. Encryption and Decryption
5.5. Key Management
5.6. Creating a Key Store for Testing
5.7. Using Multiple Keys and Key Rotation
5.8. Serving Encrypted Properties
6. Serving Alternative Formats
7. Serving Plain Text
8. Embedding the Config Server
9. Push Notifications and Spring Cloud Bus
10. Spring Cloud Config Client
10.1. Config First Bootstrap
10.2. Discovery First Bootstrap
10.3. Config Client Fail Fast
10.4. Config Client Retry
10.5. Locating Remote Configuration Resources
10.6. Specifying Multiple Urls for the Config Server
10.7. Configuring Read Timeouts
10.8. Security
10.8.1. Health Indicator
10.8.2. Providing A Custom RestTemplate
10.8.3. Vault
10.9. Nested Keys In Vault
III. Spring Cloud Netflix
11. Service Discovery: Eureka Clients
11.1. How to Include Eureka Client
11.2. Registering with Eureka
11.3. Authenticating with the Eureka Server
11.4. Status Page and Health Indicator
11.5. Registering a Secure Application
11.6. Eureka’s Health Checks
11.7. Eureka Metadata for Instances and Clients
11.7.1. Using Eureka on Cloud Foundry
11.7.2. Using Eureka on AWS
11.7.3. Changing the Eureka Instance ID
11.8. Using the EurekaClient
11.8.1. EurekaClient without Jersey
11.9. Alternatives to the Native Netflix EurekaClient
11.10. Why Is It so Slow to Register a Service?
11.11. Zones
12. Service Discovery: Eureka Server
12.1. How to Include Eureka Server
12.2. How to Run a Eureka Server
12.3. High Availability, Zones and Regions
12.4. Standalone Mode
12.5. Peer Awareness
12.6. When to Prefer IP Address
12.7. Securing The Eureka Server
12.8. JDK 11 Support
13. Circuit Breaker: Hystrix Clients
13.1. How to Include Hystrix
13.2. Propagating the Security Context or Using Spring Scopes
13.3. Health Indicator
13.4. Hystrix Metrics Stream
14. Circuit Breaker: Hystrix Dashboard
15. Hystrix Timeouts And Ribbon Clients
15.1. How to Include the Hystrix Dashboard
15.2. Turbine
15.2.1. Clusters Endpoint
15.3. Turbine Stream
16. Client Side Load Balancer: Ribbon
16.1. How to Include Ribbon
16.2. Customizing the Ribbon Client
16.3. Customizing the Default for All Ribbon Clients
16.4. Customizing the Ribbon Client by Setting Properties
16.5. Using Ribbon with Eureka
16.6. Example: How to Use Ribbon Without Eureka
16.7. Example: Disable Eureka Use in Ribbon
16.8. Using the Ribbon API Directly
16.9. Caching of Ribbon Configuration
16.10. How to Configure Hystrix Thread Pools
16.11. How to Provide a Key to Ribbon’s IRule
17. External Configuration: Archaius
18. Router and Filter: Zuul
18.1. How to Include Zuul
18.2. Embedded Zuul Reverse Proxy
18.3. Zuul Http Client
18.4. Cookies and Sensitive Headers
18.5. Ignored Headers
18.6. Management Endpoints
18.6.1. Routes Endpoint
18.6.2. Filters Endpoint
18.7. Strangulation Patterns and Local Forwards
18.8. Uploading Files through Zuul
18.9. Query String Encoding
18.10. Request URI Encoding
18.11. Plain Embedded Zuul
18.12. Disable Zuul Filters
18.13. Providing Hystrix Fallbacks For Routes
18.14. Zuul Timeouts
18.15. Rewriting the Location header
18.16. Enabling Cross Origin Requests
18.17. Metrics
18.18. Zuul Developer Guide
18.18.1. The Zuul Servlet
18.18.2. Zuul RequestContext
18.18.3. @EnableZuulProxy vs. @EnableZuulServer
18.18.4. @EnableZuulServer Filters
18.18.5. @EnableZuulProxy Filters
18.18.6. Custom Zuul Filter Examples
How to Write a Pre Filter
How to Write a Route Filter
How to Write a Post Filter
18.18.7. How Zuul Errors Work
18.18.8. Zuul Eager Application Context Loading
19. Polyglot support with Sidecar
20. Retrying Failed Requests
20.1. BackOff Policies
20.2. Configuration
20.2.1. Zuul
21. HTTP Clients
IV. Spring Cloud OpenFeign
22. Declarative REST Client: Feign
22.1. How to Include Feign
22.2. Overriding Feign Defaults
22.3. Creating Feign Clients Manually
22.4. Feign Hystrix Support
22.5. Feign Hystrix Fallbacks
22.6. Feign and @Primary
22.7. Feign Inheritance Support
22.8. Feign request/response compression
22.9. Feign logging
22.10. Feign @QueryMap support
V. Spring Cloud Stream
23. A Brief History of Spring’s Data Integration Journey
24. Quick Start
24.1. Creating a Sample Application by Using Spring Initializr
24.2. Importing the Project into Your IDE
24.3. Adding a Message Handler, Building, and Running
25. What’s New in 2.0?
25.1. New Features and Components
25.2. Notable Enhancements
25.2.1. Both Actuator and Web Dependencies Are Now Optional
25.2.2. Content-type Negotiation Improvements
25.3. Notable Deprecations
25.3.1. Java Serialization (Java Native and Kryo)
25.3.2. Deprecated Classes and Methods
26. Introducing Spring Cloud Stream
27. Main Concepts
27.1. Application Model
27.1.1. Fat JAR
27.2. The Binder Abstraction
27.3. Persistent Publish-Subscribe Support
27.4. Consumer Groups
27.5. Consumer Types
27.5.1. Durability
27.6. Partitioning Support
28. Programming Model
28.1. Destination Binders
28.2. Destination Bindings
28.3. Producing and Consuming Messages
28.3.1. Spring Integration Support
28.3.2. Using @StreamListener Annotation
28.3.3. Using @StreamListener for Content-based routing
28.3.4. Spring Cloud Function support
Functional Composition
28.3.5. Using Polled Consumers
Overview
Handling Errors
28.4. Error Handling
28.4.1. Application Error Handling
28.4.2. System Error Handling
Drop Failed Messages
DLQ - Dead Letter Queue
Re-queue Failed Messages
28.4.3. Retry Template
28.5. Reactive Programming Support
28.5.1. Reactor-based Handlers
28.5.2. Reactive Sources
29. Binders
29.1. Producers and Consumers
29.2. Binder SPI
29.3. Binder Detection
29.3.1. Classpath Detection
29.4. Multiple Binders on the Classpath
29.5. Connecting to Multiple Systems
29.6. Binding visualization and control
29.7. Binder Configuration Properties
30. Configuration Options
30.1. Binding Service Properties
30.2. Binding Properties
30.2.1. Common Binding Properties
30.2.2. Consumer Properties
30.2.3. Producer Properties
30.3. Using Dynamically Bound Destinations
31. Content Type Negotiation
31.1. Mechanics
31.1.1. Content Type versus Argument Type
31.1.2. Message Converters
31.2. Provided MessageConverters
31.3. User-defined Message Converters
32. Schema Evolution Support
32.1. Schema Registry Client
32.1.1. Schema Registry Client Properties
32.2. Avro Schema Registry Client Message Converters
32.2.1. Avro Schema Registry Message Converter Properties
32.3. Apache Avro Message Converters
32.4. Converters with Schema Support
32.5. Schema Registry Server
32.5.1. Schema Registry Server API
Registering a New Schema
Retrieving an Existing Schema by Subject, Format, and Version
Retrieving an Existing Schema by Subject and Format
Retrieving an Existing Schema by ID
Deleting a Schema by Subject, Format, and Version
Deleting a Schema by ID
Deleting a Schema by Subject
32.5.2. Using Confluent’s Schema Registry
32.6. Schema Registration and Resolution
32.6.1. Schema Registration Process (Serialization)
32.6.2. Schema Resolution Process (Deserialization)
33. Inter-Application Communication
33.1. Connecting Multiple Application Instances
33.2. Instance Index and Instance Count
33.3. Partitioning
33.3.1. Configuring Output Bindings for Partitioning
33.3.2. Configuring Input Bindings for Partitioning
34. Testing
34.1. Disabling the Test Binder Autoconfiguration
35. Health Indicator
36. Metrics Emitter
37. Samples
37.1. Deploying Stream Applications on CloudFoundry
VI. Binder Implementations
38. Apache Kafka Binder
38.1. Usage
38.2. Apache Kafka Binder Overview
38.3. Configuration Options
38.3.1. Kafka Binder Properties
38.3.2. Kafka Consumer Properties
38.3.3. Kafka Producer Properties
38.3.4. Usage examples
Example: Setting autoCommitOffset to false and Relying on Manual Acking
Example: Security Configuration
Example: Pausing and Resuming the Consumer
38.4. Error Channels
38.5. Kafka Metrics
38.6. Dead-Letter Topic Processing
38.7. Partitioning with the Kafka Binder
39. Apache Kafka Streams Binder
39.1. Usage
39.2. Kafka Streams Binder Overview
39.2.1. Streams DSL
39.3. Configuration Options
39.3.1. Kafka Streams Properties
39.3.2. TimeWindow properties:
39.4. Multiple Input Bindings
39.4.1. Multiple Input Bindings as a Sink
39.4.2. Multiple Input Bindings as a Processor
39.5. Multiple Output Bindings (aka Branching)
39.6. Message Conversion
39.6.1. Outbound serialization
39.6.2. Inbound Deserialization
39.7. Error Handling
39.7.1. Handling Deserialization Exceptions
39.7.2. Handling Non-Deserialization Exceptions
39.8. State Store
39.9. Interactive Queries
39.10. Accessing the underlying KafkaStreams object
39.11. State Cleanup
40. RabbitMQ Binder
40.1. Usage
40.2. RabbitMQ Binder Overview
40.3. Configuration Options
40.3.1. RabbitMQ Binder Properties
40.3.2. RabbitMQ Consumer Properties
40.3.3. Advanced Listener Container Configuration
40.3.4. Rabbit Producer Properties
40.4. Retry With the RabbitMQ Binder
40.4.1. Putting it All Together
40.5. Error Channels
40.6. Dead-Letter Queue Processing
40.6.1. Non-Partitioned Destinations
40.6.2. Partitioned Destinations
republishToDlq=false
republishToDlq=true
40.7. Partitioning with the RabbitMQ Binder
VII. Spring Cloud Bus
41. Quick Start
42. Bus Endpoints
42.1. Bus Refresh Endpoint
42.2. Bus Env Endpoint
43. Addressing an Instance
44. Addressing All Instances of a Service
45. Service ID Must Be Unique
46. Customizing the Message Broker
47. Tracing Bus Events
48. Broadcasting Your Own Events
48.1. Registering events in custom packages
VIII. Spring Cloud Sleuth
49. Introduction
49.1. Terminology
49.2. Purpose
49.2.1. Distributed Tracing with Zipkin
49.2.2. Visualizing errors
49.2.3. Distributed Tracing with Brave
49.2.4. Live examples
49.2.5. Log correlation
JSON Logback with Logstash
49.2.6. Propagating Span Context
Baggage versus Span Tags
49.3. Adding Sleuth to the Project
49.3.1. Only Sleuth (log correlation)
49.3.2. Sleuth with Zipkin via HTTP
49.3.3. Sleuth with Zipkin over RabbitMQ or Kafka
50. Additional Resources
51. Features
51.1. Introduction to Brave
51.1.1. Tracing
51.1.2. Local Tracing
51.1.3. Customizing Spans
51.1.4. Implicitly Looking up the Current Span
51.1.5. RPC tracing
One-Way tracing
52. Sampling
52.1. Declarative sampling
52.2. Custom sampling
52.3. Sampling in Spring Cloud Sleuth
53. Propagation
53.1. Propagating extra fields
53.1.1. Prefixed fields
53.1.2. Extracting a Propagated Context
53.1.3. Sharing span IDs between Client and Server
53.1.4. Implementing Propagation
54. Current Tracing Component
55. Current Span
55.1. Setting a span in scope manually
56. Instrumentation
57. Span lifecycle
57.1. Creating and finishing spans
57.2. Continuing Spans
57.3. Creating a Span with an explicit Parent
58. Naming spans
58.1. @SpanName Annotation
58.2. toString() method
59. Managing Spans with Annotations
59.1. Rationale
59.2. Creating New Spans
59.3. Continuing Spans
59.4. Advanced Tag Setting
59.4.1. Custom extractor
59.4.2. Resolving Expressions for a Value
59.4.3. Using the toString() method
60. Customizations
60.1. HTTP
60.2. TracingFilter
60.3. Custom service name
60.4. Customization of Reported Spans
60.5. Host Locator
61. Sending Spans to Zipkin
62. Zipkin Stream Span Consumer
63. Integrations
63.1. OpenTracing
63.2. Runnable and Callable
63.3. Hystrix
63.3.1. Custom Concurrency Strategy
63.3.2. Manual Command setting
63.4. RxJava
63.5. HTTP integration
63.5.1. HTTP Filter
63.5.2. HandlerInterceptor
63.5.3. Async Servlet support
63.5.4. WebFlux support
63.5.5. Dubbo RPC support
63.6. HTTP Client Integration
63.6.1. Synchronous Rest Template
63.6.2. Asynchronous Rest Template
Multiple Asynchronous Rest Templates
63.6.3. WebClient
63.6.4. Traverson
63.6.5. Apache HttpClientBuilder and HttpAsyncClientBuilder
63.6.6. Netty HttpClient
63.6.7. UserInfoRestTemplateCustomizer
63.7. Feign
63.8. gRPC
63.8.1. Dependencies
63.8.2. Server Instrumentation
63.8.3. Client Instrumentation
63.9. Asynchronous Communication
63.9.1. @Async Annotated methods
63.9.2. @Scheduled Annotated Methods
63.9.3. Executor, ExecutorService, and ScheduledExecutorService
Customization of Executors
63.10. Messaging
63.10.1. Spring Integration and Spring Cloud Stream
63.10.2. Spring RabbitMq
63.10.3. Spring Kafka
63.10.4. Spring JMS
63.11. Zuul
64. Running examples
IX. Spring Cloud Consul
65. Install Consul
66. Consul Agent
67. Service Discovery with Consul
67.1. How to activate
67.2. Registering with Consul
67.3. HTTP Health Check
67.3.1. Metadata and Consul tags
67.3.2. Making the Consul Instance ID Unique
67.3.3. Applying Headers to Health Check Requests
67.4. Looking up services
67.4.1. Using Ribbon
67.4.2. Using the DiscoveryClient
67.5. Consul Catalog Watch
68. Distributed Configuration with Consul
68.1. How to activate
68.2. Customizing
68.3. Config Watch
68.4. YAML or Properties with Config
68.5. git2consul with Config
68.6. Fail Fast
69. Consul Retry
70. Spring Cloud Bus with Consul
70.1. How to activate
71. Circuit Breaker with Hystrix
72. Hystrix metrics aggregation with Turbine and Consul
X. Spring Cloud Zookeeper
73. Install Zookeeper
74. Service Discovery with Zookeeper
74.1. Activating
74.2. Registering with Zookeeper
74.3. Using the DiscoveryClient
75. Using Spring Cloud Zookeeper with Spring Cloud Netflix Components
75.1. Ribbon with Zookeeper
76. Spring Cloud Zookeeper and Service Registry
76.1. Instance Status
77. Zookeeper Dependencies
77.1. Using the Zookeeper Dependencies
77.2. Activating Zookeeper Dependencies
77.3. Setting up Zookeeper Dependencies
77.3.1. Aliases
77.3.2. Path
77.3.3. Load Balancer Type
77.3.4. Content-Type Template and Version
77.3.5. Default Headers
77.3.6. Required Dependencies
77.3.7. Stubs
77.4. Configuring Spring Cloud Zookeeper Dependencies
78. Spring Cloud Zookeeper Dependency Watcher
78.1. Activating
78.2. Registering a Listener
78.3. Using the Presence Checker
79. Distributed Configuration with Zookeeper
79.1. Activating
79.2. Customizing
79.3. Access Control Lists (ACLs)
XI. Spring Cloud Security
80. Quickstart
80.1. OAuth2 Single Sign On
80.2. OAuth2 Protected Resource
81. More Detail
81.1. Single Sign On
81.2. Token Relay
81.2.1. Client Token Relay
81.2.2. Client Token Relay in Zuul Proxy
81.2.3. Resource Server Token Relay
82. Configuring Authentication Downstream of a Zuul Proxy
XII. Spring Cloud for Cloud Foundry
83. Discovery
84. Single Sign On
XIII. Spring Cloud Contract
85. Spring Cloud Contract
86. Spring Cloud Contract Verifier Introduction
86.1. History
86.2. Why a Contract Verifier?
86.2.1. Testing issues
86.3. Purposes
86.4. How It Works
86.4.1. A Three-second Tour
On the Producer Side
On the Consumer Side
86.4.2. A Three-minute Tour
On the Producer Side
On the Consumer Side
86.4.3. Defining the Contract
86.4.4. Client Side
86.4.5. Server Side
86.5. Step-by-step Guide to Consumer Driven Contracts (CDC)
86.5.1. Technical note
86.5.2. Consumer side (Loan Issuance)
86.5.3. Producer side (Fraud Detection server)
86.5.4. Consumer Side (Loan Issuance) Final Step
86.6. Dependencies
86.7. Additional Links
86.7.1. Spring Cloud Contract video
86.7.2. Readings
86.8. Samples
87. Spring Cloud Contract FAQ
87.1. Why use Spring Cloud Contract Verifier and not X ?
87.2. I don’t want to write a contract in Groovy!
87.3. What is this value(consumer(), producer()) ?
87.4. How to do Stubs versioning?
87.4.1. API Versioning
87.4.2. JAR versioning
87.4.3. Dev or prod stubs
87.5. Common repo with contracts
87.5.1. Repo structure
87.5.2. Workflow
87.5.3. Consumer
87.5.4. Producer
87.5.5. How can I define messaging contracts per topic not per producer?
For Maven Project
For Gradle Project
87.6. Do I need a Binary Storage? Can’t I use Git?
87.6.1. Protocol convention
87.6.2. Producer
Keeping contracts with the producer and stubs in an external repository
87.6.3. Consumer
87.7. Can I use the Pact Broker?
87.7.1. Pact Consumer
87.7.2. Producer
87.7.3. Pact Consumer (Producer Contract approach)
87.8. How can I debug the request/response being sent by the generated tests client?
87.8.1. How can I debug the mapping/request/response being sent by WireMock?
87.8.2. How can I see what got registered in the HTTP server stub?
87.8.3. Can I reference text from file?
88. Spring Cloud Contract Verifier Setup
88.1. Gradle Project
88.1.1. Prerequisites
88.1.2. Add Gradle Plugin with Dependencies
88.1.3. Gradle and Rest Assured 2.0
88.1.4. Snapshot Versions for Gradle
88.1.5. Add stubs
88.1.6. Run the Plugin
88.1.7. Default Setup
88.1.8. Configure Plugin
88.1.9. Configuration Options
88.1.10. Single Base Class for All Tests
88.1.11. Different Base Classes for Contracts
88.1.12. Invoking Generated Tests
88.1.13. Pushing stubs to SCM
88.1.14. Spring Cloud Contract Verifier on the Consumer Side
88.2. Maven Project
88.2.1. Add maven plugin
88.2.2. Maven and Rest Assured 2.0
88.2.3. Snapshot versions for Maven
88.2.4. Add stubs
88.2.5. Run plugin
88.2.6. Configure plugin
88.2.7. Configuration Options
88.2.8. Single Base Class for All Tests
88.2.9. Different base classes for contracts
88.2.10. Invoking generated tests
88.2.11. Pushing stubs to SCM
88.2.12. Maven Plugin and STS
88.2.13. Maven Plugin with Spock Tests
88.3. Stubs and Transitive Dependencies
88.4. Scenarios
88.5. Docker Project
88.5.1. Short intro to Maven, JARs and Binary storage
88.5.2. How it works
Environment Variables
88.5.3. Example of usage
88.5.4. Server side (nodejs)
89. Spring Cloud Contract Verifier Messaging
89.1. Integrations
89.2. Manual Integration Testing
89.3. Publisher-Side Test Generation
89.3.1. Scenario 1: No Input Message
89.3.2. Scenario 2: Output Triggered by Input
89.3.3. Scenario 3: No Output Message
89.4. Consumer Stub Generation
90. Spring Cloud Contract Stub Runner
90.1. Snapshot versions
90.2. Publishing Stubs as JARs
90.3. Stub Runner Core
90.3.1. Retrieving stubs
Stub downloading
Classpath scanning
90.3.2. Running stubs
Running using main app
HTTP Stubs
Viewing registered mappings
Messaging Stubs
90.4. Stub Runner JUnit Rule and Stub Runner JUnit5 Extension
90.4.1. Maven settings
90.4.2. Providing fixed ports
90.4.3. Fluent API
90.4.4. Stub Runner with Spring
90.5. Stub Runner Spring Cloud
90.5.1. Stubbing Service Discovery
Test profiles and service discovery
90.5.2. Additional Configuration
90.6. Stub Runner Boot Application
90.6.1. How to use it?
Stub Runner Server
Stub Runner Server Fat Jar
Spring Cloud CLI
90.6.2. Endpoints
HTTP
Messaging
90.6.3. Example
90.6.4. Stub Runner Boot with Service Discovery
90.7. Stubs Per Consumer
90.8. Common
90.8.1. Common Properties for JUnit and Spring
90.8.2. Stub Runner Stubs IDs
90.9. Stub Runner Docker
90.9.1. How to use it
90.9.2. Example of client side usage in a non JVM project
91. Stub Runner for Messaging
91.1. Stub triggering
91.1.1. Trigger by Label
91.1.2. Trigger by Group and Artifact Ids
91.1.3. Trigger by Artifact Ids
91.1.4. Trigger All Messages
91.2. Stub Runner Camel
91.2.1. Adding it to the project
91.2.2. Disabling the functionality
91.2.3. Examples
Stubs structure
Scenario 1 (no input message)
Scenario 2 (output triggered by input)
Scenario 3 (input with no output)
91.3. Stub Runner Integration
91.3.1. Adding the Runner to the Project
91.3.2. Disabling the functionality
Scenario 1 (no input message)
Scenario 2 (output triggered by input)
Scenario 3 (input with no output)
91.4. Stub Runner Stream
91.4.1. Adding the Runner to the Project
91.4.2. Disabling the functionality
Scenario 1 (no input message)
Scenario 2 (output triggered by input)
Scenario 3 (input with no output)
91.5. Stub Runner Spring AMQP
91.5.1. Adding the Runner to the Project
Triggering the message
Spring AMQP Test Configuration
92. Contract DSL
92.1. Limitations
92.2. Common Top-Level elements
92.2.1. Description
92.2.2. Name
92.2.3. Ignoring Contracts
92.2.4. Passing Values from Files
92.2.5. HTTP Top-Level Elements
92.3. Request
92.4. Response
92.5. Dynamic properties
92.5.1. Dynamic properties inside the body
92.5.2. Regular expressions
92.5.3. Passing Optional Parameters
92.5.4. Executing Custom Methods on the Server Side
92.5.5. Referencing the Request from the Response
92.5.6. Registering Your Own WireMock Extension
92.5.7. Dynamic Properties in the Matchers Sections
92.6. JAX-RS Support
92.7. Async Support
92.8. Working with Context Paths
92.9. Working with Web Flux
92.10. Messaging Top-Level Elements
92.10.1. Output Triggered by a Method
92.10.2. Output Triggered by a Message
92.10.3. Consumer/Producer
92.10.4. Common
92.11. Multiple Contracts in One File
92.12. Generating Spring REST Docs snippets from the contracts
93. Customization
93.1. Extending the DSL
93.1.1. Common JAR
93.1.2. Adding the Dependency to the Project
93.1.3. Test the Dependency in the Project’s Dependencies
93.1.4. Test a Dependency in the Plugin’s Dependencies
93.1.5. Referencing classes in DSLs
94. Using the Pluggable Architecture
94.1. Custom Contract Converter
94.1.1. Pact Converter
94.1.2. Pact Contract
94.1.3. Pact for Producers
94.1.4. Pact for Consumers
94.2. Using the Custom Test Generator
94.3. Using the Custom Stub Generator
94.4. Using the Custom Stub Runner
94.5. Using the Custom Stub Downloader
94.6. Using the SCM Stub Downloader
94.7. Using the Pact Stub Downloader
95. Spring Cloud Contract WireMock
95.1. Registering Stubs Automatically
95.2. Using Files to Specify the Stub Bodies
95.3. Alternative: Using JUnit Rules
95.4. Relaxed SSL Validation for Rest Template
95.5. WireMock and Spring MVC Mocks
95.6. Customization of WireMock configuration
95.7. Generating Stubs using REST Docs
95.8. Generating Contracts by Using REST Docs
96. Migrations
96.1. 1.0.x → 1.1.x
96.1.1. New structure of generated stubs
96.2. 1.1.x → 1.2.x
96.2.1. Custom HttpServerStub
96.2.2. New packages for generated tests
96.2.3. New Methods in TemplateProcessor
96.2.4. RestAssured 3.0
96.3. 1.2.x → 2.0.x
97. Links
XIV. Spring Cloud Vault
98. Quick Start
99. Client Side Usage
99.1. Authentication
100. Authentication methods
100.1. Token authentication
100.2. AppId authentication
100.2.1. Custom UserId
100.3. AppRole authentication
100.4. AWS-EC2 authentication
100.5. AWS-IAM authentication
100.6. Azure MSI authentication
100.7. TLS certificate authentication
100.8. Cubbyhole authentication
101. GCP-GCE authentication
102. GCP-IAM authentication
102.1. Kubernetes authentication
103. Secret Backends
103.1. Generic Backend
103.2. Versioned Key-Value Backend
103.3. Consul
103.4. RabbitMQ
103.5. AWS
104. Database backends
104.1. Database
104.2. Apache Cassandra
104.3. MongoDB
104.4. MySQL
104.5. PostgreSQL
105. Configure PropertySourceLocator behavior
106. Service Registry Configuration
107. Vault Client Fail Fast
108. Vault Client SSL configuration
109. Lease lifecycle management (renewal and revocation)
XV. Spring Cloud Gateway
110. How to Include Spring Cloud Gateway
111. Glossary
112. How It Works
113. Route Predicate Factories
113.1. After Route Predicate Factory
113.2. Before Route Predicate Factory
113.3. Between Route Predicate Factory
113.4. Cookie Route Predicate Factory
113.5. Header Route Predicate Factory
113.6. Host Route Predicate Factory
113.7. Method Route Predicate Factory
113.8. Path Route Predicate Factory
113.9. Query Route Predicate Factory
113.10. RemoteAddr Route Predicate Factory
113.10.1. Modifying the way remote addresses are resolved
114. GatewayFilter Factories
114.1. AddRequestHeader GatewayFilter Factory
114.2. AddRequestParameter GatewayFilter Factory
114.3. AddResponseHeader GatewayFilter Factory
114.4. Hystrix GatewayFilter Factory
114.5. FallbackHeaders GatewayFilter Factory
114.6. PrefixPath GatewayFilter Factory
114.7. PreserveHostHeader GatewayFilter Factory
114.8. RequestRateLimiter GatewayFilter Factory
114.8.1. Redis RateLimiter
114.9. RedirectTo GatewayFilter Factory
114.10. RemoveNonProxyHeaders GatewayFilter Factory
114.11. RemoveRequestHeader GatewayFilter Factory
114.12. RemoveResponseHeader GatewayFilter Factory
114.13. RewritePath GatewayFilter Factory
114.14. RewriteResponseHeader GatewayFilter Factory
114.15. SaveSession GatewayFilter Factory
114.16. SecureHeaders GatewayFilter Factory
114.17. SetPath GatewayFilter Factory
114.18. SetResponseHeader GatewayFilter Factory
114.19. SetStatus GatewayFilter Factory
114.20. StripPrefix GatewayFilter Factory
114.21. Retry GatewayFilter Factory
114.22. RequestSize GatewayFilter Factory
115. Global Filters
115.1. Combined Global Filter and GatewayFilter Ordering
115.2. Forward Routing Filter
115.3. LoadBalancerClient Filter
115.4. Netty Routing Filter
115.5. Netty Write Response Filter
115.6. RouteToRequestUrl Filter
115.7. Websocket Routing Filter
115.8. Gateway Metrics Filter
115.9. Making An Exchange As Routed
116. TLS / SSL
116.1. TLS Handshake
117. Configuration
117.1. Fluent Java Routes API
117.2. DiscoveryClient Route Definition Locator
118. Reactor Netty Access Logs
119. CORS Configuration
120. Actuator API
120.1. Retrieving route filters
120.1.1. Global Filters
120.1.2. Route Filters
120.2. Refreshing the route cache
120.3. Retrieving the routes defined in the gateway
120.4. Retrieving information about a particular route
120.5. Creating and deleting a particular route
120.6. Recap: list of all endpoints
121. Developer Guide
121.1. Writing Custom Route Predicate Factories
121.2. Writing Custom GatewayFilter Factories
121.3. Writing Custom Global Filters
121.4. Writing Custom Route Locators and Writers
122. Building a Simple Gateway Using Spring MVC or Webflux
XVI. Spring Cloud Function
123. Introduction
124. Getting Started
125. Building and Running a Function
126. Function Catalog and Flexible Function Signatures
126.1. Java 8 function support
126.2. Kotlin Lambda support
127. Standalone Web Applications
128. Standalone Streaming Applications
129. Deploying a Packaged Function
130. Functional Bean Definitions
130.1. Comparing Functional with Traditional Bean Definitions
130.2. Testing Functional Applications
130.3. Limitations of Functional Bean Declaration
131. Dynamic Compilation
132. Serverless Platform Adapters
132.1. AWS Lambda
132.1.1. Introduction
132.1.2. Notes on JAR Layout
132.1.3. Upload
132.1.4. Platfom Specific Features
HTTP and API Gateway
132.2. Azure Functions
132.2.1. Notes on JAR Layout
132.2.2. Build
132.2.3. Running the sample
132.3. Apache Openwhisk
132.3.1. Quick Start
XVII. Spring Cloud Kubernetes
133. Why do you need Spring Cloud Kubernetes?
134. DiscoveryClient for Kubernetes
135. Kubernetes PropertySource implementations
135.1. ConfigMap PropertySource
135.2. Secrets PropertySource
135.3. PropertySource Reload
136. Ribbon discovery in Kubernetes
137. Kubernetes Awareness
137.1. Kubernetes Profile Autoconfiguration
138. Pod Health Indicator
139. Leader Election
140. Security Configurations inside Kubernetes
140.1. Namespace
140.2. Service Account
141. Examples
142. Other Resources
143. Building
143.1. Basic Compile and Test
143.2. Documentation
143.3. Working with the code
143.3.1. Importing into eclipse with m2eclipse
143.3.2. Importing into eclipse without m2eclipse
144. Contributing
144.1. Sign the Contributor License Agreement
144.2. Code of Conduct
144.3. Code Conventions and Housekeeping
XVIII. Spring Cloud GCP Reference Documentation
145. Introduction
146. Dependency Management
147. Getting started
147.1. Spring Initializr
147.2. Code Samples
147.3. Code Challenges
147.4. Getting Started Guides
148. Spring Cloud GCP Core
148.1. Project ID
148.2. Credentials
148.2.1. Scopes
148.3. Environment
148.4. Spring Initializr
149. Google Cloud Pub/Sub
149.1. Pub/Sub Operations & Template
149.1.1. Publishing to a topic
JSON support
149.1.2. Subscribing to a subscription
149.1.3. Pulling messages from a subscription
149.2. Pub/Sub management
149.2.1. Creating a topic
149.2.2. Deleting a topic
149.2.3. Listing topics
149.2.4. Creating a subscription
149.2.5. Deleting a subscription
149.2.6. Listing subscriptions
149.3. Configuration
149.4. Sample
150. Spring Resources
150.1. Google Cloud Storage
150.2. Configuration
150.3. Sample
151. Spring JDBC
151.1. Prerequisites
151.2. Spring Boot Starter for Google Cloud SQL
151.2.1. DataSource creation flow
151.2.2. Troubleshooting tips
Connection issues
Errors like c.g.cloud.sql.core.SslSocketFactory : Re-throwing cached exception due to attempt to refresh instance information too soon after error
PostgreSQL: java.net.SocketException: already connected issue
151.3. Samples
152. Spring Integration
152.1. Channel Adapters for Cloud Pub/Sub
152.1.1. Inbound channel adapter
152.1.2. Outbound channel adapter
152.1.3. Header mapping
152.2. Sample
152.3. Channel Adapters for Google Cloud Storage
152.3.1. Inbound channel adapter
152.3.2. Inbound streaming channel adapter
152.3.3. Outbound channel adapter
152.4. Sample
153. Spring Cloud Stream
153.1. Overview
153.2. Configuration
153.2.1. Producer Destination Configuration
153.2.2. Consumer Destination Configuration
153.3. Sample
154. Spring Cloud Sleuth
154.1. Tracing
154.2. Spring Boot Starter for Stackdriver Trace
154.3. Integration with Logging
154.4. Sample
155. Stackdriver Logging
155.1. Web MVC Interceptor
155.2. Logback Support
155.2.1. Log via API
155.2.2. Log via Console
155.3. Sample
156. Spring Cloud Config
156.1. Configuration
156.2. Quick start
156.3. Refreshing the configuration at runtime
156.4. Sample
157. Spring Data Cloud Spanner
157.1. Configuration
157.1.1. Cloud Spanner settings
157.1.2. Repository settings
157.1.3. Autoconfiguration
157.2. Object Mapping
157.2.1. Constructors
157.2.2. Table
SpEL expressions for table names
157.2.3. Primary Keys
157.2.4. Columns
157.2.5. Embedded Objects
157.2.6. Relationships
157.2.7. Supported Types
157.2.8. Lists
157.2.9. Lists of Structs
157.2.10. Custom types
157.2.11. Custom Converter for Struct Array Columns
157.3. Spanner Operations & Template
157.3.1. SQL Query
157.3.2. Read
157.3.3. Advanced reads
Stale read
Read from a secondary index
Read with offsets and limits
Sorting
Partial read
Summary of options for Query vs Read
157.3.4. Write / Update
Insert
Update
Upsert
Partial Update
157.3.5. DML
157.3.6. Transactions
Read/Write Transaction
Read-only Transaction
Declarative Transactions with @Transactional Annotation
157.3.7. DML Statements
157.4. Repositories
157.4.1. CRUD Repository
157.4.2. Paging and Sorting Repository
157.4.3. Spanner Repository
157.5. Query Methods
157.5.1. Query methods by convention
157.5.2. Custom SQL/DML query methods
Query methods with named queries properties
Query methods with annotation
157.5.3. Projections
157.5.4. REST Repositories
157.6. Database and Schema Admin
157.7. Sample
158. Spring Data Cloud Datastore
158.1. Configuration
158.1.1. Cloud Datastore settings
158.1.2. Repository settings
158.1.3. Autoconfiguration
158.2. Object Mapping
158.2.1. Constructors
158.2.2. Kind
158.2.3. Keys
158.2.4. Fields
158.2.5. Supported Types
158.2.6. Custom types
158.2.7. Collections and arrays
158.2.8. Custom Converter for collections
158.3. Relationships
158.3.1. Embedded Entities
158.3.2. Ancestor-Descendant Relationships
158.3.3. Key Reference Relationships
158.4. Datastore Operations & Template
158.4.1. GQL Query
158.4.2. Find by ID(s)
Indexes
Read with offsets, limits, and sorting
Partial read
158.4.3. Write / Update
Partial Update
158.4.4. Transactions
Declarative Transactions with @Transactional Annotation
158.4.5. Read-write support for maps
158.5. Repositories
158.5.1. Query methods by convention
158.5.2. Custom GQL query methods
Query methods with annotation
Query methods with named queries properties
158.5.3. Transactions
158.5.4. Projections
158.5.5. REST Repositories
158.6. Sample
159. Cloud Memorystore for Redis
159.1. Spring Caching
160. Cloud Identity-Aware Proxy (IAP) Authentication
160.1. Configuration
160.2. Sample
161. Google Cloud Vision
161.1. Cloud Vision Template
161.2. Detect Image Labels Example
161.3. Sample
162. Cloud Foundry
XIX. Appendix: Compendium of Configuration Properties