userver: samples/grpc_middleware_service/configs/static_config.yaml
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
samples/grpc_middleware_service/configs/static_config.yaml
components_manager:
    components:
        logging:
            fs-task-processor: fs-task-processor
            loggers:
                default:
                    file_path: '@stderr'
                    level: debug
                    overflow_behavior: discard
 
# /// [gRPC middleware sample - static config client middleware]
        # yaml
        # Contains machinery common to all gRPC clients
        grpc-client-common:
            # The TaskProcessor for blocking connection initiation
            blocking-task-processor: grpc-blocking-task-processor
        # Creates gRPC clients
        grpc-client-factory:
            channel-args: {}
# /// [gRPC middleware sample - static config client middleware]
 
        # Our wrapper around the generated client for GreeterService
# /// [gRPC middleware sample - static config greeter-client]
        greeter-client:
            # The service endpoint (URI). We talk to our own service,
            # which is kind of pointless, but works for an example.
            endpoint: $greeter-endpoint
# /// [gRPC middleware sample - static config greeter-client]
 
        congestion-control:
 
        grpc-chaos-client:
# /// [static config grpc-auth-client]
        grpc-auth-client:
 
        grpc-client-middlewares-pipeline:
            middlewares:
                grpc-auth-client:
                    enabled: true  # register the middleware in the pipeline
# /// [static config grpc-auth-client]
                grpc-chaos-client:
                    enabled: true  # register the middleware in the pipeline
 
# /// [static config grpc-server-middlewares-pipeline]
        grpc-server-meta-filter:
            headers:
              - global-header
# /// [grpc-server-auth static config]
        grpc-server-auth:
 
        grpc-server-middlewares-pipeline:
            middlewares:
                grpc-server-auth:  # register the middleware in the pipeline
                    enabled: true
# /// [grpc-server-auth static config]
                grpc-server-meta-filter:  # register the middleware in the pipeline
                    enabled: true
# /// [static config grpc-server-middlewares-pipeline]
 
        # Common configuration for gRPC server
        grpc-server:
            # The single listening port for incoming RPCs
            port: 8091
            completion-queue-count: 3
 
        # Our GreeterService implementation
# /// [gRPC greeter-service sample]
        # yaml
        greeter-service:
            task-processor: main-task-processor
            greeting-prefix: Hello
            middlewares:
                grpc-server-meta-filter:
                    # The middleware of this service will get this header instead of 'global-header'
                    headers:
                      - specific-header
# /// [gRPC greeter-service sample]
 
        # In this example, the tests still communicate with the microservice
        # using HTTP, so we still need an HTTP server and an HTTP handler.
        server:
            listener:
                port: 8092
                task_processor: main-task-processor
 
        greeter-http-handler:
            path: /hello
            method: POST
            task_processor: main-task-processor
 
        testsuite-support:
 
    default_task_processor: main-task-processor  # Task processor in which components start.
 
    task_processors:
        grpc-blocking-task-processor:  # For blocking gRPC channel creation
            worker_threads: 2
            thread_name: grpc-worker
        main-task-processor:           # For non-blocking operations
            worker_threads: 8
        fs-task-processor:             # For blocking filesystem operations
            worker_threads: 2