Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


These support forums are now closed for new topics and comments.
Please head on over to http://eureka.ucommerce.net/ for support.

  • Ali Sheikh Taheri 470 posts 1648 karma points c-trib
    Sep 10, 2013 @ 18:47
    Ali Sheikh Taheri
    0

    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

  • Morten Skjoldager 440 posts 1499 karma points
    Sep 11, 2013 @ 09:25
    Morten Skjoldager
    0

    Hi Ali,

    Can you tell me what version of uCommerce you installed? 

     

  • Ali Sheikh Taheri 470 posts 1648 karma points c-trib
    Sep 11, 2013 @ 10:51
    Ali Sheikh Taheri
    0

    Hi,

    I am using uCommerce Developer Edition v4.0.0.23249.

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 11:06
    ffz
    0

    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!

  • Ali Sheikh Taheri 470 posts 1648 karma points c-trib
    Sep 11, 2013 @ 11:08
    Ali Sheikh Taheri
    0

    ffz , I've the same issue.

    and so tricky to add loads of dll into reference specially with having uCommerce folder in bin.

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 11:25
    ffz
    0

    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.

  • Morten Skjoldager 440 posts 1499 karma points
    Sep 11, 2013 @ 12:42
    Morten Skjoldager
    0

    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 

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 13:27
    ffz
    0

    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?

  • Morten Skjoldager 440 posts 1499 karma points
    Sep 11, 2013 @ 13:37
    Morten Skjoldager
    0

    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. 

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 13:57
    ffz
    0

    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?

  • Morten Skjoldager 440 posts 1499 karma points
    Sep 11, 2013 @ 14:48
    Morten Skjoldager
    0

    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:

    1. Create empty web application
    2. Install Umbraco via nuget
    3. setup umbraco with your desired database and stuff
    4. Install the uCommerce package 
    5. Take all of the uCommerce dll's (not the dependencies) and put them in a lib folder.
    6. Reference Those dll's from the lib folder

    Following above steps should not leave you with anything that conflicts. 

  • Ali Sheikh Taheri 470 posts 1648 karma points c-trib
    Sep 11, 2013 @ 14:52
    Ali Sheikh Taheri
    0

    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!

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 15:22
    ffz
    0

    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....

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 15:35
    ffz
    0

    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!

  • ffz 9 posts 29 karma points
    Sep 11, 2013 @ 15:48
    ffz
    0

    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.

  • Morten Skjoldager 440 posts 1499 karma points
    Sep 12, 2013 @ 08:18
    Morten Skjoldager
    0

    @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.

Please Sign in or register to post replies

Write your reply to:

Draft