2016-03-28 3 views
0

Jenkinsを使用してqaサーバーにWCFアプリケーションをデプロイしました。私は次のエラーメッセージを受け取りました。Jenkinsを使用してQAにwcfアプリケーションをデプロイし、Jenkinsサーバーのファイルを参照します。

 System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information. 
      at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module) 
      at System.Reflection.RuntimeModule.GetTypes() 
      at System.Reflection.Assembly.GetTypes() 
      at System.ComponentModel.Composition.Hosting.AssemblyCatalog.get_InnerCatalog() 
      at System.ComponentModel.Composition.Hosting.AssemblyCatalog.GetExports(ImportDefinition definition) 
      at System.Linq.Enumerable.<SelectManyIterator>d__14`2.MoveNext() 
      at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InternalGetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) 
      at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.AggregateExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExports(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) 
      at System.ComponentModel.Composition.Hosting.CompositionContainer.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ImportEngine.TryGetExports(ExportProvider provider, ComposablePart part, ImportDefinition definition, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportSubset(PartManager partManager, IEnumerable`1 imports, AtomicComposition atomicComposition) 
      at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportsStateMachine(PartManager partManager, ComposablePart part) 
      at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImports(PartManager partManager, ComposablePart part, Boolean shouldTrackImports) 
      at System.ComponentModel.Composition.Hosting.ImportEngine.SatisfyImports(ComposablePart part) 
      at System.ComponentModel.Composition.Hosting.CompositionServices.TryInvoke(Action action) 
      at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.Compose(CompositionBatch batch) 
      at IRWebSvc.MEF..ctor() in e:\Jenkins\Jobs\IRWebSvc\workspace\Jenkins__IRWebSvc_dev\IRWebSvc\MEF.cs:line 24 
      at IRWebSvc.IRSvc.AddPage(String source, String xmlRequest) in e:\Jenkins\Jobs\IRWebSvc\workspace\Jenkins__IRWebSvc_dev\IRWebSvc\IRSvc.svc.cs:line 30 

それは電子内のファイルを参照する理由はわからない。:\ジェンキンス\ジョブ\ IRWebSvc \ワークスペース\ Jenkins__IRWebSvc_dev \ IRWebSvcフォルダを。ここで私はGithubからソースコードをチェックアウトします。

ここで私はアプリケーションをコンパイルしてパッケージ化します。

  <Target Name="Compile" DependsOnTargets="WebConfigTransform"> 
      <MSBuild Projects="@(SolutionFile)" 
        Targets="Rebuild" 
        Properties="OutDir=%(BuildArtifacts.FullPath);Configuration=$(Configuration);Platform=$(BuildPlatform)" /> 
      </Target> 



      <Target Name="Package" DependsOnTargets="Compile"> 
      <PropertyGroup> 
       <PackageDir>@(BuildArtifacts)\</PackageDir> 
       <Source>@(BuildArtifacts)@(Website)</Source> 
       <Destination>@(BuildArtifacts)@(PackageFile)</Destination> 
      </PropertyGroup> 

      <MakeDir Directories="$(PackageDir)" /> 
      <Exec Command='"@(MsDeploy)" -verb:sync -source:iisApp="$(Source)" -dest:package="$(Destination)"' /> 
      </Target> 

答えて

0

私はMEFのインターフェースを変更しました。そのモジュールを使用するすべてのモジュールを再デプロイする必要があります。私は使用する必要があるものだけを配備しました。なぜ私はそのエラーメッセージを受け取ります。

関連する問題