Embedded in MVC3

Feb 17, 2014 at 1:18 AM

When trying to use app_data folder (or other variations):
var path = Path.Combine(HostingEnvironment.MapPath(@"~/App_Data"), "raptordb");
_raptorDB = RaptorDB.RaptorDB.Open(path);

I get the error:

Access to the path 'C:\Program Files (x86)\IIS Express-RaptorDB.config' is denied.

Can the document store be used in MVC3 apps?

If so what am I missing?

Feb 17, 2014 at 6:40 AM
Try adding a tailing / and possibly converting / to \ for file names ->
var path = Path.Combine(HostingEnvironment.MapPath(@"~/App_Data"), "/raptordb"); 
path = path.Replace("/","\\");
Feb 17, 2014 at 7:48 AM

The path was already:


without any replace operations.

Still getting:

Access to the path 'C:\Program Files (x86)\IIS Express\-RaptorDB.config' is denied.


Feb 17, 2014 at 7:51 AM
When I change to my dev server I get the same error with a different path:

Access to the path 'C:\Program Files (x86)\Common Files\Microsoft Shared\DevServer\11.0\-RaptorDB.config' is denied.

Feb 17, 2014 at 8:35 AM
The Key value store does not have a "-RaptorDB.config" file, that is in the doc store version.

You can edit the raptordb.cs file (at the top) to fix the paths.