Design Puzzle

D

dwa

A general .NET releated design question:

Short Verssion:

What is the best way to have a data access layer target a different database
at run-time, without having to pass in some identifier or string to select a
database?

Background:

Many of our clients have very similar database processing requirements:
users, logins, products, product lines, etc., and we've been able to design
a generic database that works across a wide variety of business domains.
Along with this, we have data access components, of course. When we deploy,
we put a different instance of the database in place for each client, but
would like to re-use the same data access components for each application.

I thought about setting a variable in the AppDomain with SetData, which
could be referenced in the data access layer, but I'm not sure this will
work if the call into the access layer is remoted (?)

1. If we make a call into a remoted object, say on a different machine, does
that call run under the AppDomain of the caller? (my guess would be "no"
but...)

2. Is there some other context that we can use to determine the application
that is calling it?

Thanks,

- da


--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,822
Latest member
israfaceZa

Latest Threads

Top