我正在ServiceStack
3.9.71 上开发服务基础架构(管理面板+网络服务)。当我开始开发过程时,没有错误或警告,所有项目都被编译并运行完美。当我尝试在Linux上部署应用程序时出现问题:管理控制面板未在那里启动(mono fastcgi-server4
)。
我备份了所有并删除了解决方案中所有项目的所有ServiceStack
和ServiceStack Razor
依赖项,然后重新安装它们。之后,在编译器日志中出现许多错过类型的警告。我试图运行应用程序,但它们会因错误而崩溃。
编译器日志如下所示。我正在使用俄语版Visual Studio 2012 Express
,所以我用Google翻译器翻译了所有消息。
1>------ Rebuilding all files started: Project: App.Common, Configuration: Debug Any CPU ------
1> App.Common -> d:\projects\app\App.Common\bin\Debug\App.Common.dll
2>------ Rebuilding all files started: Project: App.Models, Configuration: Debug Any CPU ------
3>------ Rebuilding all files started: Project: App.Roles, Configuration: Debug Any CPU ------
2> App.Models -> d:\projects\app\App.Models\bin\Debug\App.Models.dll
3> App.Roles -> d:\projects\app\App.Roles\bin\Debug\App.Roles.dll
4>------ Rebuilding all files started: Project: App.ServiceDTO, Configuration: Debug Any CPU ------
4> App.ServiceDTO -> d:\projects\app\App.ServiceDTO\bin\Debug\App.ServiceDTO.dll
5>------ Rebuilding all files started: Project: App.Services, Configuration: Debug Any CPU ------
6>------ Rebuilding all files started: Project: App.Administration, Configuration: Debug Any CPU ------
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.ServiceInterface.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IService", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.ServiceInterface.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IService", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.ApiMemberAttribute", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
5>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
5> App.Services -> d:\projects\app\App.Services\bin\App.Services.dll
7>------ Rebuilding all files started: Project: App.Tests, Configuration: Debug Any CPU ------
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.ServiceInterface.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IService", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.Common.ServiceModel.MetadataTypesConfig", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Common.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.ApiMemberAttribute", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.ServiceInterface.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IService", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.Razor.3.9.71\lib\net40\ServiceStack.Razor.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.Razor.3.9.71\lib\net40\ServiceStack.Razor.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.Razor.3.9.71\lib\net40\ServiceStack.Razor.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6>d:\projects\app\packages\ServiceStack.Razor.3.9.71\lib\net40\ServiceStack.Razor.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
6> App.Administration -> d:\projects\app\App.Administration\bin\App.Administration.dll
7>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.ServiceInterface.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IService", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
7> App.Tests -> d:\projects\app\App.Tests\bin\Debug\App.Tests.dll
8>------ Rebuilding all files started: Project: App, Configuration: Debug Any CPU ------
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.ServiceHost.IServiceRunner`1", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8>d:\projects\app\packages\ServiceStack.3.9.71\lib\net35\ServiceStack.dll : warning CS1684: Could not find type "ServiceStack.IO.IVirtualPathProvider", which, according to the link must be defined in "d:\projects\app\packages\ServiceStack.Common.3.9.11\lib\net35\ServiceStack.Interfaces.dll"
8> App -> d:\projects\app\App\bin\Debug\App.exe
========== Rebuilding all: successful: 8 errors: 0, skipped: 0 ==========
我没有在其他项目上发现同样的问题,这也是基于我两个月前开发的ServiceStack 3.9.71。
答案 0 :(得分:6)
我通过逐步重新安装所有 ServiceStack
的依赖项解决了这个问题:
Install-Package ServiceStack -Version 3.9.71
Install-Package ServiceStack.Common -Version 3.9.71
Install-Package ServiceStack.Text -Version 3.9.71
# optionally
Install-Package ServiceStack.Razor -Version 3.9.71
小心删除您使用它的每个项目中ServiceStack
的{{1}}的所有条目。我还从解决方案中删除了packages.config
文件夹。我发现问题是通过在软件包存储库中自动链接> 4.0 版本库。