The Ucommerce folder in the bin is there by purpose. Otherwise it would not even work installed on IIS. Ucommerce adds assemblyBinding to the Web.config the only idea I had is to add these conflicting dll's via an alias to the references but that require adjustments in the Umbraco implementation or in Raven. Both seems to me impossible because those dll's are not under my control.
Hi guys. So i just installed Latest version of Umbraco via nuget and installed ucommerce 4.0 as a package in the new website. Having to run your umbracosite directly in your visual studio solution (point IIS site to the root of the site) is a very normal way to develop - at least that's what im used to do. Also when i develop i usually take those dependencies that i have and put it in a lib folder ouside the website root and reference them from there. Also i only reference uCommerce dll's.
Our dependencies (uCommerce dependencies) is placed in bin/ucommerce in order prevent conflicts with other packages - and as of 4.0 not to conflict with lucene either as umbraco uses that too. If you need to use lucene you would have to use Umbraco's version. When i reference ucommerce dll's only there should be no problem.
Do you get the problem when you try to reference Lucene only ?
Ok, just add UCommerce dll's to the References.
Under the WebApplication Project > Web > Servers : I take 'Use Local IIS Web server' > Use IIS Express
Is that possible or do I need to setup an IIS Website?
One more question regarding the Razor store. When install that it adds a Raven folder. The code inside of the folder requires also to reference of Raven. This causes a conflict with Lucene and Raven. Raven is also expected to be deployed into bin/uCommerce on build.
This is from my point the only problem. this is just the case when I have the Razor store 2.0. Version 1.x is fine because it doesn't uses Raven.
Is there a way to include Raven (as used in the Razor store 2.0)t into the WebProject?
You don't need to include everything in your project. including the raven folder also gives me compile errors. Say you install the razor store you could include masterpages, css, images and other stuff that doesn't require compilation. Whenever you reference stuff it has to go into the bin folder, which is causing errors. When your'e working with uCommerce shouldn't have to reference anything else but the uCommerce dll's.
Ok,
I include everything but not the Raven folder. The stuff in that folder is precompiled also.
Just to understand that correctly:
When I put the Ucommerce dll's that I've copied from bin and bin/uCommerce into a lib folder outside of my web project (like NuGet does with the packages folder) and using them in a c# context within the WebApplication everything is fine. I could add a precompiler statement which copies the dll's from ther into the targeting bin (sub)folder to have a single point for all the dll's when I build the project. On a postcompiler I'd remove the dll's copied by the reference into the bin which actually belong to the bin/uCommerce output folder. Then everything should be clean.
Yeah, however you don't have to fiddle with anything at all. Say you install uCommerce only. Then everything should just work.
Of cource you cannot start developing anything as you do not reference uCommerce in your solution (consider the site and the solution as two individual things). So in order to start developing you need to reference the uCommerce dll's - which already is part of your bin folder. You could just reference them directly from the bin, but to have everything seperated (the solution and the site), you should reference them from somewhere else - like nuget does with the package structure. It may sound confusing but i think the trick here is to seperate those things.
Another approach is to simply seperate the site and the solution. However it is more unconvenient as you would have to copy your own compiled dll's together with everything else related.
I thought about doing a quick 2 minutes video on how to get running but descriped in steps, here's what you do:
Create empty web application
Install Umbraco via nuget
setup umbraco with your desired database and stuff
Install the uCommerce package
Take all of the uCommerce dll's (not the dependencies) and put them in a lib folder.
Reference Those dll's from the lib folder
Following above steps should not leave you with anything that conflicts.
I did the 6 steps.
All fine when I just reference UCommerce dll's.
The separating approach sounds interesting as far as I already planed a businesslogic layer where I probably will use UCommerce references also.
But using them in a Razor script file which would still be in the WebApplication project will still require using it via reference in the WebApplication.
I just thought that a Ucommerce Wrapper dll with all the public API could be a solution where you use this in your references and the wrapper links the calling to the assembly's in the bin/uCommerce folder. So you use the one wrapper as a developer and you'd have to ensure that the dependencies will be in the bin/uCommerce and that's it.
I just saw that it seems to be exactly that way wrapped ;)
The only UCommerce dll in bin/uCommerce is UCommerce.Umbraco.Installer.dll - I don't think you'd need this referenced, do you?
And everything else should be fine!
When installing the Razor store 2.0.x, do not add the Raven folder to the WebApplilation project and everything works!
I just got it running that way and I play around with it on an IIS Express debug session in Visual Studio without runtime or compiler errors!
And follow the approach of putting the libs into an external/extra folder for the uCommerce libs, do not include the bin/uCommerce folder to the project. That will confuse the runtime about the log4net version.
uCommerce as WebApplication
Hi,
I've installed Umbraco 6.1.5 via NuGet and setup the project as Web Application.
Then installed uCommerce and in bin folder there are a lot of dlls which needs to be transferred to Reference within the solution.
Is there any best practice for that? having uCommerce folder within the bin folder makes is so tricky for WebApplicaiton.
Any Suggestion ?
Cheers Ali
Hi Ali,
Can you tell me what version of uCommerce you installed?
Hi,
I am using uCommerce Developer Edition v4.0.0.23249.
Me too, same setup. The issue I'm getting is a conflict with the Lucene version used in Ucommerce or actually used in the Raven libs.
Begging for an advice on how to set this up as a WebApplication or any other guide on how to set up a development environment in Visual Studio!
ffz , I've the same issue.
and so tricky to add loads of dll into reference specially with having uCommerce folder in bin.
The Ucommerce folder in the bin is there by purpose. Otherwise it would not even work installed on IIS. Ucommerce adds assemblyBinding to the Web.config the only idea I had is to add these conflicting dll's via an alias to the references but that require adjustments in the Umbraco implementation or in Raven. Both seems to me impossible because those dll's are not under my control.
Hi guys. So i just installed Latest version of Umbraco via nuget and installed ucommerce 4.0 as a package in the new website. Having to run your umbracosite directly in your visual studio solution (point IIS site to the root of the site) is a very normal way to develop - at least that's what im used to do. Also when i develop i usually take those dependencies that i have and put it in a lib folder ouside the website root and reference them from there. Also i only reference uCommerce dll's.
Our dependencies (uCommerce dependencies) is placed in bin/ucommerce in order prevent conflicts with other packages - and as of 4.0 not to conflict with lucene either as umbraco uses that too. If you need to use lucene you would have to use Umbraco's version. When i reference ucommerce dll's only there should be no problem.
Do you get the problem when you try to reference Lucene only ?
Hope that helps. Otherwise let me know.
Regards
Morten
Ok, just add UCommerce dll's to the References. Under the WebApplication Project > Web > Servers : I take 'Use Local IIS Web server' > Use IIS Express Is that possible or do I need to setup an IIS Website?
One more question regarding the Razor store. When install that it adds a Raven folder. The code inside of the folder requires also to reference of Raven. This causes a conflict with Lucene and Raven. Raven is also expected to be deployed into bin/uCommerce on build. This is from my point the only problem. this is just the case when I have the Razor store 2.0. Version 1.x is fine because it doesn't uses Raven. Is there a way to include Raven (as used in the Razor store 2.0)t into the WebProject?
You don't need to include everything in your project. including the raven folder also gives me compile errors. Say you install the razor store you could include masterpages, css, images and other stuff that doesn't require compilation. Whenever you reference stuff it has to go into the bin folder, which is causing errors. When your'e working with uCommerce shouldn't have to reference anything else but the uCommerce dll's.
Ok, I include everything but not the Raven folder. The stuff in that folder is precompiled also. Just to understand that correctly: When I put the Ucommerce dll's that I've copied from bin and bin/uCommerce into a lib folder outside of my web project (like NuGet does with the packages folder) and using them in a c# context within the WebApplication everything is fine. I could add a precompiler statement which copies the dll's from ther into the targeting bin (sub)folder to have a single point for all the dll's when I build the project. On a postcompiler I'd remove the dll's copied by the reference into the bin which actually belong to the bin/uCommerce output folder. Then everything should be clean.
Is that close to best practice?
Yeah, however you don't have to fiddle with anything at all. Say you install uCommerce only. Then everything should just work.
Of cource you cannot start developing anything as you do not reference uCommerce in your solution (consider the site and the solution as two individual things). So in order to start developing you need to reference the uCommerce dll's - which already is part of your bin folder. You could just reference them directly from the bin, but to have everything seperated (the solution and the site), you should reference them from somewhere else - like nuget does with the package structure. It may sound confusing but i think the trick here is to seperate those things.
Another approach is to simply seperate the site and the solution. However it is more unconvenient as you would have to copy your own compiled dll's together with everything else related.
I thought about doing a quick 2 minutes video on how to get running but descriped in steps, here's what you do:
Following above steps should not leave you with anything that conflicts.
thanks Morten,
how about the dlls in the bin/ucommerce folder? Do I need to add them to reference too?
If you could do a 2 minutes video would be great.
Thanks for your help!
I'd love to see the video ;)
I did the 6 steps. All fine when I just reference UCommerce dll's.
The separating approach sounds interesting as far as I already planed a businesslogic layer where I probably will use UCommerce references also.
But using them in a Razor script file which would still be in the WebApplication project will still require using it via reference in the WebApplication.
I just thought that a Ucommerce Wrapper dll with all the public API could be a solution where you use this in your references and the wrapper links the calling to the assembly's in the bin/uCommerce folder. So you use the one wrapper as a developer and you'd have to ensure that the dependencies will be in the bin/uCommerce and that's it.
Just a quick thought could be also a bad idea....
I just saw that it seems to be exactly that way wrapped ;) The only UCommerce dll in bin/uCommerce is UCommerce.Umbraco.Installer.dll - I don't think you'd need this referenced, do you? And everything else should be fine!
When installing the Razor store 2.0.x, do not add the Raven folder to the WebApplilation project and everything works!
I just got it running that way and I play around with it on an IIS Express debug session in Visual Studio without runtime or compiler errors!
And follow the approach of putting the libs into an external/extra folder for the uCommerce libs, do not include the bin/uCommerce folder to the project. That will confuse the runtime about the log4net version.
@ali,
no, only reference those named like uCommerce all of our dependencies are located in 'bin/ucommerce'. Leave those alone. You should not need them.
is working on a reply...