By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,052 Members | 1,551 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,052 IT Pros & Developers. It's quick & easy.

MS Enterprise Library

P: n/a
Hi,

I have started using MS Enterprise Library for the data access layer
and found it great. I have changed to coding on another machine though
and didn't think it necessary to a full install of the Enterprise
Library. This caused a problem that the following article solves:

http://scottonwriting.net/sowblog/posts/3406.aspx

Does this however mean I am going to run into all sorts of problems
using the enterprise library if I host my website on a shared hosting
solution where I don't have any control on what is installed on the
servers?

Thanks in advance

Dave

Oct 2 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Dave,

All you should have to do is modify the configuration of the data access
block so that it doesn't use any instrumentation (at least, any kind that is
stored on the server in the form of a performance counter, for example). On
a shared hosting environment, you won't have access to the performance
counters, or wmi for example.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"bungle" <bu****@wizardbuy.comwrote in message
news:11**********************@h48g2000cwc.googlegr oups.com...
Hi,

I have started using MS Enterprise Library for the data access layer
and found it great. I have changed to coding on another machine though
and didn't think it necessary to a full install of the Enterprise
Library. This caused a problem that the following article solves:

http://scottonwriting.net/sowblog/posts/3406.aspx

Does this however mean I am going to run into all sorts of problems
using the enterprise library if I host my website on a shared hosting
solution where I don't have any control on what is installed on the
servers?

Thanks in advance

Dave

Oct 2 '06 #2

P: n/a

From personal experience.

No, once you get that stuff out, its stable.

You have to deploy 3 files though.

..Data
..Common
..Configuration

but I have sucessfully deployed the altered code to a hosting company.

Here are some other links and snipplets:

Common Build Properties were changed from Default:

http://blogs.msdn.com/tomholl/archiv...x?Pending=true
If you are deploying to an environment where the instrumentation cannot be
used,
it's pretty easy to disable it, but you will need to recompile the code.
Luckily all the instrumentation code is wrapped around conditional
compilation directives,
so you won't need to edit any source files directly.
Just go into the Project Properties dialog for the Common project,
and under Configuration Properties\Build,
find the Conditional Compilation Properties property
and remove ;USEWMI;USEEVENTLOG;USEPERFORMANCECOUNTER (or
any combination of these that you don't want).
Once you recompile, the relevant instrumentation code will be disabled.
Of course, it is still possible to configure the Logging &
Instrumentation Application Block to use WMI or Event Log,
so make sure you also choose appropriate settings for your environment
if you are using that block.

http://channel9.msdn.com/wiki/defaul...riseLibraryFAQ
Open up the EnterpriseLibrary.sln and modify the Configuration
Properties\Build\Conditional Constants
of the EnterpriseLibrary.Common project.
Remove the USEWMI;USEEVENTLOG;USEPERFORMANCECOUNTER constants.
By removing these constants,
all of the internal Enterprise Library instrumentation will be disabled.
Recompile.
"bungle" <bu****@wizardbuy.comwrote in message
news:11**********************@h48g2000cwc.googlegr oups.com...
Hi,

I have started using MS Enterprise Library for the data access layer
and found it great. I have changed to coding on another machine though
and didn't think it necessary to a full install of the Enterprise
Library. This caused a problem that the following article solves:

http://scottonwriting.net/sowblog/posts/3406.aspx

Does this however mean I am going to run into all sorts of problems
using the enterprise library if I host my website on a shared hosting
solution where I don't have any control on what is installed on the
servers?

Thanks in advance

Dave

Oct 2 '06 #3

P: n/a
Thanks guys - very useful information as always :)

Was worried I would have to refactor all my code, but not anymore.

Thanks again

Oct 3 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.