who does the port mapping ? the host
who has to inform the container ? the host
that's about it
docker compose up -e <service>:<env>:<value>
but i don't think that's a thing
.MapGet("some/url/structure", (string foo, int bar) => HandleRequest(foo, bar));
foo
and bar
there, can you just give it MyRequestObject
that has properties Foo
and Bar
and have it do model binding?
Result<T>
type to let you signal error results without exceptions, for cases where errors are expected and not exceptional
return Results.NotFound<User>(query.UserId);
rather than having to throw new UserNotFoundException(query.UserId);
var result = await _mediator.Send(query);
return MapToResponse(result);
that looks promising but might require consuming applications to write binders for everything