i can't run kigg

Nov 28, 2010 at 7:27 PM
Edited Nov 28, 2010 at 8:20 PM

I compiled the kigg in VS2010.

When i start it, it throws the following exception:

Server Error in '/' Application.

The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.Data.MetadataException: The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource.

Source Error: 

Line 43:         }
Line 44: 
Line 45:         public Database(string connectionString) :
Line 46:             base(connectionString, _defaultContainerName)
Line 47:         {   


Source File: C:\Projects\Kigg_3a9b436eace5\Source\EntityFramework\Repository\Database\Database.cs    Line: 45 

Stack Trace: 

[MetadataException: The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource.]
   System.Data.Metadata.Edm.MetadataArtifactLoader.Create(String path, ExtensionCheck extensionCheck, String validExtension, ICollection`1 uriRegistry, MetadataArtifactAssemblyResolver resolver) +3656234
   System.Data.EntityClient.EntityConnection.SplitPaths(String paths) +659
   System.Data.EntityClient.EntityConnection.GetMetadataWorkspace(Boolean initializeAllCollections) +148
   System.Data.Objects.ObjectContext.RetrieveMetadataWorkspaceFromConnection() +26
   System.Data.Objects.ObjectContext..ctor(EntityConnection connection, Boolean isConnectionConstructor) +172
   System.Data.Objects.ObjectContext..ctor(String connectionString, String defaultContainerName) +27
   Kigg.EF.Repository.Database..ctor(String connectionString) in C:\Projects\Kigg_3a9b436eace5\Source\EntityFramework\Repository\Database\Database.cs:45
   Kigg.EF.Repository.DatabaseFactory.Create() in C:\Projects\Kigg_3a9b436eace5\Source\EntityFramework\Repository\Database\DatabaseFactory.cs:35
   Kigg.EF.Repository.BaseRepository`2..ctor(IDatabaseFactory factory) in C:\Projects\Kigg_3a9b436eace5\Source\EntityFramework\Repository\BaseRepository.cs:23
   Kigg.EF.Repository.UserRepository..ctor(IDatabaseFactory factory) in C:\Projects\Kigg_3a9b436eace5\Source\EntityFramework\Repository\UserRepository.cs:18
   BuildUp_Kigg.EF.Repository.UserRepository(IBuilderContext ) +316
   Microsoft.Practices.ObjectBuilder2.DynamicMethodBuildPlan.BuildUp(IBuilderContext context) +42
   Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +306
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +119

[BuildFailedException: The current build operation (build key Build Key[Kigg.EF.Repository.UserRepository, EntityFramework]) failed: The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource. (Strategy type BuildPlanStrategy, index 3)]
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +349
   Microsoft.Practices.Unity.ObjectBuilder.NamedTypeDependencyResolverPolicy.Resolve(IBuilderContext context) +173
   BuildUp_Kigg.Repository.LoggingUserRepository(IBuilderContext ) +230

[InvalidOperationException: The parameter innerRepository could not be resolved when attempting to call constructor Kigg.Repository.LoggingUserRepository(Kigg.Repository.IUserRepository innerRepository).]
   Microsoft.Practices.ObjectBuilder2.DynamicMethodConstructorStrategy.ThrowForResolutionFailed(Exception inner, String parameterName, String constructorSignature, IBuilderContext context) +177
   BuildUp_Kigg.Repository.LoggingUserRepository(IBuilderContext ) +340
   Microsoft.Practices.ObjectBuilder2.DynamicMethodBuildPlan.BuildUp(IBuilderContext context) +42
   Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +306
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +119

[BuildFailedException: The current build operation (build key Build Key[Kigg.Repository.LoggingUserRepository, Logging]) failed: The parameter innerRepository could not be resolved when attempting to call constructor Kigg.Repository.LoggingUserRepository(Kigg.Repository.IUserRepository innerRepository). (Strategy type BuildPlanStrategy, index 3)]
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +349
   Microsoft.Practices.Unity.ObjectBuilder.NamedTypeDependencyResolverPolicy.Resolve(IBuilderContext context) +173
   BuildUp_Kigg.Repository.CachingUserRepository(IBuilderContext ) +233

[InvalidOperationException: The parameter innerRepository could not be resolved when attempting to call constructor Kigg.Repository.CachingUserRepository(Kigg.Repository.IUserRepository innerRepository, System.Int32 noOfUsersCacheCount, System.Single usersCacheDurationInMinutes, System.Single userCacheDurationInMinutes).]
   Microsoft.Practices.ObjectBuilder2.DynamicMethodConstructorStrategy.ThrowForResolutionFailed(Exception inner, String parameterName, String constructorSignature, IBuilderContext context) +177
   BuildUp_Kigg.Repository.CachingUserRepository(IBuilderContext ) +808
   Microsoft.Practices.ObjectBuilder2.DynamicMethodBuildPlan.BuildUp(IBuilderContext context) +42
   Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +306
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +119

[BuildFailedException: The current build operation (build key Build Key[Kigg.Repository.CachingUserRepository, null]) failed: The parameter innerRepository could not be resolved when attempting to call constructor Kigg.Repository.CachingUserRepository(Kigg.Repository.IUserRepository innerRepository, System.Int32 noOfUsersCacheCount, System.Single usersCacheDurationInMinutes, System.Single userCacheDurationInMinutes). (Strategy type BuildPlanStrategy, index 3)]
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +349
   Microsoft.Practices.Unity.ObjectBuilder.NamedTypeDependencyResolverPolicy.Resolve(IBuilderContext context) +173
   BuildUp_Kigg.Infrastructure.CreateDefaultUsers(IBuilderContext ) +343

[InvalidOperationException: The parameter userRepository could not be resolved when attempting to call constructor Kigg.Infrastructure.CreateDefaultUsers(Kigg.DomainObjects.IDomainObjectFactory factory, Kigg.Repository.IUserRepository userRepository, Kigg.Infrastructure.DefaultUser[] users).]
   Microsoft.Practices.ObjectBuilder2.DynamicMethodConstructorStrategy.ThrowForResolutionFailed(Exception inner, String parameterName, String constructorSignature, IBuilderContext context) +177
   BuildUp_Kigg.Infrastructure.CreateDefaultUsers(IBuilderContext ) +608
   Microsoft.Practices.ObjectBuilder2.DynamicMethodBuildPlan.BuildUp(IBuilderContext context) +42
   Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +306
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +119

[BuildFailedException: The current build operation (build key Build Key[Kigg.Infrastructure.CreateDefaultUsers, createDefaultUsers]) failed: The parameter userRepository could not be resolved when attempting to call constructor Kigg.Infrastructure.CreateDefaultUsers(Kigg.DomainObjects.IDomainObjectFactory factory, Kigg.Repository.IUserRepository userRepository, Kigg.Infrastructure.DefaultUser[] users). (Strategy type BuildPlanStrategy, index 3)]
   Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +349
   Microsoft.Practices.ObjectBuilder2.Builder.BuildUp(IReadWriteLocator locator, ILifetimeContainer lifetime, IPolicyList policies, IStrategyChain strategies, Object buildKey, Object existing) +102
   Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name) +215

[ResolutionFailedException: Resolution of the dependency failed, type = "Kigg.Infrastructure.IBootstrapperTask", name = "createDefaultUsers". Exception message is: The current build operation (build key Build Key[Kigg.Infrastructure.CreateDefaultUsers, createDefaultUsers]) failed: The parameter userRepository could not be resolved when attempting to call constructor Kigg.Infrastructure.CreateDefaultUsers(Kigg.DomainObjects.IDomainObjectFactory factory, Kigg.Repository.IUserRepository userRepository, Kigg.Infrastructure.DefaultUser[] users). (Strategy type BuildPlanStrategy, index 3)]
   Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name) +275
   Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, String name) +42
   Microsoft.Practices.Unity.UnityContainer.Resolve(Type t, String name) +40
   Microsoft.Practices.Unity.<ResolveAll>d__4.MoveNext() +315
   Microsoft.Practices.Unity.<ResolveAll>d__0`1.MoveNext() +344
   Kigg.EnumerableExtension.ForEach(IEnumerable`1 enumerable, Action`1 action) in C:\Projects\Kigg_3a9b436eace5\Source\Core\Extension\EnumerableExtension.cs:12
   Kigg.Infrastructure.Bootstrapper.Run() in C:\Projects\Kigg_3a9b436eace5\Source\Core\Infrastructure\Bootstrapper\Bootstrapper.cs:21
   Kigg.Web.GlobalApplication.OnStart() in C:\Projects\Kigg_3a9b436eace5\Source\Web\Global.asax.cs:11
   Kigg.Web.GlobalApplication.Application_Start() in C:\Projects\Kigg_3a9b436eace5\Source\Web\Global.asax.cs:23

 what's the problem with this, what i forgot to do?

Nov 28, 2010 at 8:31 PM

Now i fixed it, sorry for stupid question

Jan 7, 2011 at 2:05 AM

I have the same problem. Can you explain how you fixed it? Thanks.

Jan 7, 2011 at 8:03 AM

I copied all DomainObjects.* files from \Source\SharedFiles\ to \Source\Web\App_Data\

Jan 15, 2011 at 5:09 AM

I'm running the app with linq2sql for now. I will give EF a shoot soon.  Thanks.

Jan 15, 2011 at 2:12 PM
Edited Jan 15, 2011 at 2:13 PM

I also completely removed EF support from the engine. linq2sql seems to work faster