DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/index.php)
-   ASP.NET (http://www.daniweb.com/forums/forum18.html)
-   -   the beer house web starter kit - msdtc (http://www.daniweb.com/forums/thread113923.html)

john8098 Mar 14th, 2008 11:20 am
the beer house web starter kit - msdtc
 
Most of the asp.net shared web hosting didn't support msdtc ( Microsoft Distributed Transaction Coordinator ) , when using Thebeerhouse starter kit , you would encounter error when click submit now ( go paypal section ) & in admin list of user and order also result in error. because this all need to use msdtc to update the data. But i have modified the code. It run on godaddy.com shared hosting enviroment. my web site is won-mart, any one need help, feel free to ask me.

ytliow Jul 5th, 2008 4:50 pm
Re: the beer house web starter kit - msdtc
 
Quote:

Originally Posted by john8098 (Post 560948)
Most of the asp.net shared web hosting didn't support msdtc ( Microsoft Distributed Transaction Coordinator ) , when using Thebeerhouse starter kit , you would encounter error when click submit now ( go paypal section ) & in admin list of user and order also result in error. because this all need to use msdtc to update the data. But i have modified the code. It run on godaddy.com shared hosting enviroment. my web site is won-mart, any one need help, feel free to ask me.

Yes, it will be greatly appreciated if you share your fix.

Houstonman Jul 8th, 2008 11:42 pm
Re: the beer house web starter kit - msdtc
 
Hey John,
I checked out your site and registered everything worked great...nice site! can you share the code to get thebeerhouse to work with paypal on godaddy's servers?
Thanks
Tim

blickberry Dec 19th, 2008 7:09 pm
Re: the beer house web starter kit - msdtc - Not too scary
 
MSDTC is not technically required on the BeerHouse, just SQL forces you down that path - TBH uses nested transactions over the same connection - an outer tran to create the order ID and the inner ones to add each product to that order - comitting all transactions in one big bang at the end.

I also began coding round it and got it working by closing the tran to get the order ID and opening a new one to add each product (storing order ID in a local var and passing it through each time) - dig around in MB.TheBeerHouse.BLL.Store. But you don't want to do that -

Just add this to the end of the connection string ...

;Enlist=false

...this tells sql server not to worry about promoting transactions and just get on with the job - as long as the connection remains open you are laughing and the site will work without begging for MSDTC to be turned on. NO CODE REQUIRED!!

The up side - the web site will perform a bit quicker and you can host it anywhere.

The down side - you are not using the full promoted transaction scope of SQL 2005 and run a miniscule risk of the transaction not rolling back if it loses the connection half way through. TBH stores the order in the database anyway so the user can go to the orders page an finish at a later date.

Have fun! John ...c/o blickberry.com (work in progress)


All times are GMT -4. The time now is 8:08 am.

Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC