Skip to content

Instantly share code, notes, and snippets.

@ahmetkucukoglu
Created November 12, 2019 18:42
Show Gist options
  • Save ahmetkucukoglu/2eb477946fa09ad2b69beca74f816708 to your computer and use it in GitHub Desktop.
Save ahmetkucukoglu/2eb477946fa09ad2b69beca74f816708 to your computer and use it in GitHub Desktop.
AWS Serverless Kuyruklama Sistemi Geliştirme - Startup.cs v2
namespace AwsDotnetCsharp
{
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.DependencyInjection;
public class Startup
{
public void ConfigureServices(IServiceCollection services)
{
services.AddAWSService<Amazon.SQS.IAmazonSQS>();
services.AddAWSService<Amazon.DynamoDBv2.IAmazonDynamoDB>();
services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
}
else
{
app.UseHsts();
}
app.UseHttpsRedirection();
app.UseMvc();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment