You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

25 lines
738 B

  1. using Microsoft.AspNetCore.Builder;
  2. using Microsoft.Extensions.DependencyInjection;
  3. namespace Sample.AzureServiceBus.MySql
  4. {
  5. public class Startup
  6. {
  7. public void ConfigureServices(IServiceCollection services)
  8. {
  9. services.AddCap(x =>
  10. {
  11. x.UseMySql("Server=localhost;Database=testcap;UserId=root;Password=123123;");
  12. x.UseAzureServiceBus("Endpoint=sb://testcap.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=<yourkey>");
  13. x.UseDashboard();
  14. });
  15. services.AddMvc();
  16. }
  17. public void Configure(IApplicationBuilder app)
  18. {
  19. app.UseMvc();
  20. }
  21. }
  22. }