Commit dab9d644 authored by yangxiaodong's avatar yangxiaodong

refactor.

parent 715f634a
namespace Cap.Consistency
{
public class BrokerOptions
{
public string HostName { get; set; }
}
}
\ No newline at end of file
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;
using Cap.Consistency.Routing;
namespace Cap.Consistency.Builder
{
public class ConsistencyMiddleware
{
private readonly ITopicRoute _router;
public ConsistencyMiddleware(ITopicRoute router) {
_router = router;
}
public async Task Invoke() {
var context = new TopicRouteContext();
context.Routes.Add(_router);
await _router.RouteAsync(context);
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment