-
Notifications
You must be signed in to change notification settings - Fork 48
Migrate Beta4 to rc1
Tom Kuijsten edited this page Sep 30, 2016
·
3 revisions
There are a couple of breaking changes in rc1.
The "Devkoes" prefix is removed from all namespaces.
The HttpServer.RegisterRoute
is removed.
The HttpServer(int port)
is obsolete and will be removed in the stable release.
To support unified configuration we moved to a slightly different approach of creating a HttpServer
. This sample was used until beta4:
var httpServer = new HttpServer(8800);
httpServer.RegisterRoute("api", restRouteHandler);
await httpServer.StartServerAsync();
And this will be replaced in rc1 with:
var configuration = new HttpServerConfiguration()
.ListenOnPort(8800)
.RegisterRoute("api", restRouteHandler)
.EnableCors();
var httpServer = new HttpServer(configuration);
await httpServer.StartServerAsync();