The Wayback Machine - https://web.archive.org/web/20220419090446/https://github.com/line/armeria
Skip to content

Your go-to microservice framework for any situation, from the creator of Netty et al. You can build any type of microservice leveraging your favorite technologies, including gRPC, Thrift, Kotlin, Retrofit, Reactive Streams, Spring Boot and Dropwizard.

master
Switch branches/tags
Code

Latest commit

Motivation:

`RoutingResult.path()` should return a mapped path by `Route`.
Let's say a service which routes to `/users/{userId}` is prefixed
with `/api/v1`. If a request path is `/api/v1/users/1234`,
- `ServiceRequestContext.path()` is equal to `/api/v1/users/1234`
- `ServiceRequestContext.mappedPath()` should be equal to `/users/1234`

Before #4086, a prefixed path is internally mapped with
`PrefixPathMapping`. So a prefix path is correctly stripped.
https://github.com/line/armeria/blob/d336d8981f03001f5a12ecae3363e98b698bb08b/core/src/main/java/com/linecorp/armeria/server/PrefixPathMapping.java#L67
\#4086 introduced `Route.withPrefix()` and all `PathMapping`s are able
to be prefixed. Consequently, other `PathMapping` implementations such
as `ExactPathMapping`, should remove the prefix when building
`RoutingResult.path()`.

Modifications:

- Remove the prefix of a request path when a `RoutingContext` is applied
  to:
  - `ExactPathMapping`
  - `GlobPathMapping`,
  - `ParameterizedPathMapping`
  - `RegexPathMappingWithPrefix`

Result:

Fix a regression introduced by #4086
58dff88

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
it
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Visit the official web site for more information.

Armeria

Build a reactive microservice at your pace, not theirs.

Armeria is your go-to microservice framework for any situation. You can build any type of microservice leveraging your favorite technologies, including gRPC, Thrift, Kotlin, Retrofit, Reactive Streams, Spring Boot and Dropwizard.

It is open-sourced by the creator of Netty and his colleagues at LINE Corporation.

Requirements

How to reach us — chat, questions and newsletters

Visit the community to chat with us, ask questions and learn how to contribute.

Hall of fame

See the complete list of our contributors.

Contributors