The following errors occurred while attempting to load the app.
- No 'Configuration' method was found in class 'WebApp.Startup, WebApp, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'.
To disable OWIN startup discovery, add the appSetting owin:AutomaticAppStartup with a value of "false" in your web.config.
To specify the OWIN startup Assembly, Class, or Method, add the appSetting owin:AppStartup with the fully qualified startup class or configuration method name in your web.config.

解决办法:

添加Startup 类

    public partial class Startup
{
// 有关配置身份验证的详细信息,请访问 http://go.microsoft.com/fwlink/?LinkId=301864
public void ConfigureAuth(IAppBuilder app)
{
AntiForgeryConfig.UniqueClaimTypeIdentifier = ClaimTypes.Name;
app.UseCookieAuthentication(new CookieAuthenticationOptions
{
AuthenticationType = DefaultAuthenticationTypes.ApplicationCookie,
LoginPath = new PathString(IdentityExtention.AuthUrl)
});
}
}

添加调用

[assembly: OwinStartup(typeof(WebApp.Startup))]

namespace WebApp
{
public partial class Startup
{
public void Configuration(IAppBuilder app)
{
ConfigureAuth(app);
}
}
}

  

No 'Configuration' method was found in class 'WebApp.Startup的更多相关文章

  1. Spartan-6 FPGA Configuration

    These configuration pins serve as the interface for a number of different configuration modes: • JTA ...

  2. Topshelf Configuration z

    Topshelf Configuration While the Quickstart gives you enough to get going, there are many more featu ...

  3. MySQL 5.6 Reference Manual-14.4 InnoDB Configuration

    14.4 InnoDB Configuration 14.4.1 InnoDB Initialization and Startup Configuration 14.4.2 Configuring ...

  4. The configuration file 'appsettings.json' was not found and is not optional

    问: .Net Core: Application startup exception: System.IO.FileNotFoundException: The configuration file ...

  5. Getting Started with OWIN and Katana(Console 代替iis 制作 web服务的简单方案)

    Open Web Interface for .NET (OWIN) defines an abstraction between .NET web servers and web applicati ...

  6. ssm基础搭建步骤

    今天搭建新的项目环境,从网上找了些ssm的搭建步骤,终于找到了一位csdn的大佬,可以说写的特别详细,按照上面步骤搭建即可,为了方便日后参考,转载到本人博客,原文链接:https://blog.csd ...

  7. 简单读!spring-mvc源码之url的暴露之路

    spring中,注册controller的url有多种方式: 1. 你可以啥都不都干,直接使用 @RequestMapping 注解上体路径,然后加上 <component-scan>, ...

  8. 构建 Owin 中间件 来获取客户端IP地址

    Not so long ago, we discussed on this blog the possible ways of retrieving the client’s IP address i ...

  9. ssh框架配置过程

    1.pom.xml配置依赖 <?xml version="1.0" encoding="UTF-8"?> <project xmlns=&qu ...

随机推荐

  1. React同构起步

    React同构从0到1 前言 如果你想快速做react同构的新项目建议你去了解next.js等成熟框架,本教程仅限于想了解如何从0开始实现一个同构环境过程的同学,对于想改造现有spa项目的同学也很有帮 ...

  2. BATJ的常见java面试题

    JAVA基础 JAVA中的几种基本数据类型是什么,各自占用多少字节. String类能被继承吗,为什么. 不可以,因为String类有final修饰符,而final修饰的类是不能被继承的,实现细节不允 ...

  3. Being a Good Boy in Spring Festival

    Being a Good Boy in Spring Festival Problem Description 一年在外 父母时刻牵挂春节回家 你能做几天好孩子吗寒假里尝试做做下面的事情吧 陪妈妈逛一 ...

  4. Python 入门之 内置模块 -- collections模块

    Python 入门之 内置模块 -- collections模块 1.collections -- 基于Python自带的数据类型之上额外增加的几个数据类型 from collections ​ 在内 ...

  5. python with hadoop

    python with  hdfs hdfs 可以在 linux 本地操作 bin/hdfs dfs -ls /foo 但是这种只能在 命令行 操作. 通常我们需要在程序中实现远程操作,python ...

  6. Select 和Alert

    Select 和Alert使用前都必须先导入 from selenium.webdriver.common.alert import Alert from selenium.webdriver.sup ...

  7. 剑指offer-递归和循环-python

    -斐波那契数列- 大家都知道斐波那契数列(1.1.2.3.5.8.13.21.34.……),现在要求输入一个整数n,请你输出斐波那契数列的第n项(从0开始,第0项为0). n<=39 斐波那契数 ...

  8. view视图总结

    视图实质上存储的是一段sql. 创建方式: 1.create view  视图名 as  子查询语句   , 特点:与主表数据同步,对当前视图进行修改,会同时将根表一并修改.  2.create or ...

  9. jQuery改变元素class属性

    //去掉class属性 $(this).parent('li').removeClass("prev_selected"); //去掉同兄弟的class属性. $(this).pa ...

  10. Python笔试面试题目及答案

    1.is 和==的区别? is:比较的是两个对象的id值是否相等,也就是比较俩对象是否为同一个实例对象.是否指向同一个内存地址 == : 比较的两个对象的内容/值是否相等,默认会调用对象的eq()方法 ...