Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
A

AspireYarp

> 编程语言
Open source

Yarp resource for Aspire.Hosting

100 stars0 likes2 views
WebsiteGitHub

About

Yarp resource for Aspire.Hosting

Aspire.Hosting.Yarp

This is a sample project that shows how use YARP in development to route between multiple services.

Getting Started

There are 2 ways to use the YARP resource:

  1. Code based routes
csharp
var builder = DistributedApplication.CreateBuilder(args);

var app1 = builder.AddProject("app1");

var app2 = builder.AddProject("app2");

builder.AddYarp("ingress")
       .WithEndpoint(hostPort: 8001, scheme: "http")
       .Route("app1", path: "/app1", target: app1)
       .Route("app2", path: "/app2", target: app2);

builder.Build().Run();
  1. Configuration based routes
csharp
var builder = DistributedApplication.CreateBuilder(args);

var app1 = builder.AddProject("app1");

var app2 = builder.AddProject("app2");

builder.AddYarp("ingress")
    .WithEndpoint(hostPort: 8001, scheme: "http")
    .WithReference(app1)
    .WithReference(app2)
    .LoadFromConfiguration("ReverseProxy");

builder.Build().Run();
…

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C#

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 18, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言