Architecture question

R

Ron M. Newman

Hi,

I have a web application in mind that I'd like to implement. It's a
classical web/databse application. I find myself thinking about how to
design it.

- It's clear I'd like the 'presentation layer' to be separate.
- I'd like to have the 'application' layer in separate non graphic/non
webform related objects.
- I'd like to design the 'application layer' to be code-reentrant.

My questions are:

1) Can this be done naturaly with ASP.NET? without bending the system?
2) Who takes care of the threads? is it enough that I make my 'application
layer' threadsafe and the calls from the web forms are going to be
maintained by the web-server (thread wise)?

Thanks !
 
A

Alvin Bruney [MVP]

- I'd like to have the 'application' layer in separate non graphic/non
webform related objects.
Good. put it in a class library.
- I'd like to design the 'application layer' to be code-reentrant.
I don't know what that means. I really mean that I don't think you and I are
thinking of the same thing. It would help for you to clarify. Usually,
threads operate on discrete portions of code which are always tagged as
re-entrant. The fact that it is even callable from a thread implies
re-entrancy. An application layer really has no concept of re-entrancy
because a layer is high level view of integrated portions of code. In fact,
this point is really moot because I am not aware of any high level language
which isn't re-entrant.
My questions are:

1) Can this be done naturaly with ASP.NET? without bending the system?
ASP.NET was designed with this in mind. So yes.
2) Who takes care of the threads?
ASP.NET can take care of thread management only if you use the threadpool
otherwise, in the conventional sense, and outside of the threadpool, you are
responsible for managing the threads.

is it enough that I make my 'application
layer' threadsafe
I'm not sure what you mean here. Variables are the ones which concern
themselves with thread safety.

and the calls from the web forms are going to be
maintained by the web-server (thread wise)?
You said you were separating presentation from application layer. With that
architecture, web form code would not maintain anything but the presentation
layer. Your application layer would be responsible for managing threading.
 
R

Ron M. Newman

Hi,

Thanks for your answers. I appreciate this.

Thanks!

Alvin Bruney said:
- I'd like to have the 'application' layer in separate non graphic/non
webform related objects.
Good. put it in a class library.
- I'd like to design the 'application layer' to be code-reentrant.
I don't know what that means. I really mean that I don't think you and I are
thinking of the same thing. It would help for you to clarify. Usually,
threads operate on discrete portions of code which are always tagged as
re-entrant. The fact that it is even callable from a thread implies
re-entrancy. An application layer really has no concept of re-entrancy
because a layer is high level view of integrated portions of code. In fact,
this point is really moot because I am not aware of any high level language
which isn't re-entrant.
My questions are:

1) Can this be done naturaly with ASP.NET? without bending the system?
ASP.NET was designed with this in mind. So yes.
2) Who takes care of the threads?
ASP.NET can take care of thread management only if you use the threadpool
otherwise, in the conventional sense, and outside of the threadpool, you are
responsible for managing the threads.

is it enough that I make my 'application
layer' threadsafe
I'm not sure what you mean here. Variables are the ones which concern
themselves with thread safety.

and the calls from the web forms are going to be
maintained by the web-server (thread wise)?
You said you were separating presentation from application layer. With that
architecture, web form code would not maintain anything but the presentation
layer. Your application layer would be responsible for managing threading.


--
Regards,
Alvin Bruney [ASP.NET MVP]
Got tidbits? Get it here...
http://tinyurl.com/3he3b
Ron M. Newman said:
Hi,

I have a web application in mind that I'd like to implement. It's a
classical web/databse application. I find myself thinking about how to
design it.

- It's clear I'd like the 'presentation layer' to be separate.
- I'd like to have the 'application' layer in separate non graphic/non
webform related objects.
- I'd like to design the 'application layer' to be code-reentrant.

My questions are:

1) Can this be done naturaly with ASP.NET? without bending the system?
2) Who takes care of the threads? is it enough that I make my 'application
layer' threadsafe and the calls from the web forms are going to be
maintained by the web-server (thread wise)?

Thanks !
 

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

Top