Threading model for MTS components 
Author Message
 Threading model for MTS components

Hi guys!

Can anybody please tell me what is the default threading model while
creating an MTS component
through C++ ATL COM AppWizard?

Is that the best threading model to pull XML from a site, transform and then
spit onto a web page?
Also if I need to optimize the component any further, what steps would be
needed?

Thanx in advance.

Nadeem Rauf



Mon, 30 Jun 2003 15:01:27 GMT  
 Threading model for MTS components
Are you asking what the _best_ threading model would be? Or what is the
deafult?
The default in ATL is STA objects. If you want to take advantage of pooling
(MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

--
Assaf Lavie.


Quote:
> Hi guys!

> Can anybody please tell me what is the default threading model while
> creating an MTS component
> through C++ ATL COM AppWizard?

> Is that the best threading model to pull XML from a site, transform and
then
> spit onto a web page?
> Also if I need to optimize the component any further, what steps would be
> needed?

> Thanx in advance.

> Nadeem Rauf



Mon, 30 Jun 2003 15:35:08 GMT  
 Threading model for MTS components
Hi Assaf!
Thanx for the response. However i am still not fully satisfied with your
answer.

I wanted to know the default threading model only for those ATL that create
MTS objects.
The cause of confusion are the following lines of code that are written
after creating an
MTS component through the ATL COM AppWizard:

    val ThreadingModel = s 'Both'
(in the Registrar Script Code .RGS file)
and
     public CComObjectRootEx<CComSingleThreadModel>,          (in the Class
declarations)
and then
    #define _ATL_APARTMENT_THREADED                              (in the
StdAfx.h file)

Though I will not be using COM+ but I need to make sure what threading model
is being used, as well as what is
the best threading model in this regard. I would greatly appreciate if you
could also suggest the best way to port
the existing code into using the new threading model.

Thanx in advance.

Nadeem Rauf


Quote:
> Are you asking what the _best_ threading model would be? Or what is the
> deafult?
> The default in ATL is STA objects. If you want to take advantage of
pooling
> (MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

> --
> Assaf Lavie.



> > Hi guys!

> > Can anybody please tell me what is the default threading model while
> > creating an MTS component
> > through C++ ATL COM AppWizard?

> > Is that the best threading model to pull XML from a site, transform and
> then
> > spit onto a web page?
> > Also if I need to optimize the component any further, what steps would
be
> > needed?

> > Thanx in advance.

> > Nadeem Rauf



Mon, 30 Jun 2003 23:26:11 GMT  
 Threading model for MTS components
Hi Assaf!
Thanx for the response. However i am still not fully satisfied with your
answer.

I wanted to know the default threading model only for those ATL that create
MTS objects.
The cause of confusion are the following lines of code that are written
after creating an
MTS component through the ATL COM AppWizard:

    val ThreadingModel = s 'Both'
(in the Registrar Script Code .RGS file)
and
     public CComObjectRootEx<CComSingleThreadModel>,          (in the Class
declarations)
and then
    #define _ATL_APARTMENT_THREADED                              (in the
StdAfx.h file)

Though I will not be using COM+ but I need to make sure what threading model
is being used, as well as what is
the best threading model in this regard. I would greatly appreciate if you
could also suggest the best way to port
the existing code into using the new threading model.

Thanx in advance.

Nadeem Rauf


Quote:
> Are you asking what the _best_ threading model would be? Or what is the
> deafult?
> The default in ATL is STA objects. If you want to take advantage of
pooling
> (MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

> --
> Assaf Lavie.



> > Hi guys!

> > Can anybody please tell me what is the default threading model while
> > creating an MTS component
> > through C++ ATL COM AppWizard?

> > Is that the best threading model to pull XML from a site, transform and
> then
> > spit onto a web page?
> > Also if I need to optimize the component any further, what steps would
be
> > needed?

> > Thanx in advance.

> > Nadeem Rauf



Mon, 30 Jun 2003 23:27:26 GMT  
 Threading model for MTS components
Hi Assaf!
Thanx for the response. However i am still not fully satisfied with your
answer.

I wanted to know the default threading model only for those ATL that create
MTS objects.
The cause of confusion are the following lines of code that are written
after creating an
MTS component through the ATL COM AppWizard:

    val ThreadingModel = s 'Both'
(in the Registrar Script Code .RGS file)
and
     public CComObjectRootEx<CComSingleThreadModel>,          (in the Class
declarations)
and then
    #define _ATL_APARTMENT_THREADED                              (in the
StdAfx.h file)

Though I will not be using COM+ but I need to make sure what threading model
is being used, as well as what is
the best threading model in this regard. I would greatly appreciate if you
could also suggest the best way to port
the existing code into using the new threading model.

Thanx in advance.

Nadeem Rauf


Quote:
> Are you asking what the _best_ threading model would be? Or what is the
> deafult?
> The default in ATL is STA objects. If you want to take advantage of
pooling
> (MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

> --
> Assaf Lavie.



> > Hi guys!

> > Can anybody please tell me what is the default threading model while
> > creating an MTS component
> > through C++ ATL COM AppWizard?

> > Is that the best threading model to pull XML from a site, transform and
> then
> > spit onto a web page?
> > Also if I need to optimize the component any further, what steps would
be
> > needed?

> > Thanx in advance.

> > Nadeem Rauf



Mon, 30 Jun 2003 23:19:39 GMT  
 Threading model for MTS components
Hi Assaf!
Thanx for the response. However i am still not fully satisfied with your
answer.

I wanted to know the default threading model only for those ATL that create
MTS objects.
The cause of confusion are the following lines of code that are written
after creating an
MTS component through the ATL COM AppWizard:

    val ThreadingModel = s 'Both'
(in the Registrar Script Code .RGS file)
and
     public CComObjectRootEx<CComSingleThreadModel>,          (in the Class
declarations)
and then
    #define _ATL_APARTMENT_THREADED                              (in the
StdAfx.h file)

Though I will not be using COM+ but I need to make sure what threading model
is being used, as well as what is
the best threading model in this regard. I would greatly appreciate if you
could also suggest the best way to port
the existing code into using the new threading model.

Thanx in advance.

Nadeem Rauf


Quote:
> Are you asking what the _best_ threading model would be? Or what is the
> deafult?
> The default in ATL is STA objects. If you want to take advantage of
pooling
> (MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

> --
> Assaf Lavie.



> > Hi guys!

> > Can anybody please tell me what is the default threading model while
> > creating an MTS component
> > through C++ ATL COM AppWizard?

> > Is that the best threading model to pull XML from a site, transform and
> then
> > spit onto a web page?
> > Also if I need to optimize the component any further, what steps would
be
> > needed?

> > Thanx in advance.

> > Nadeem Rauf



Mon, 30 Jun 2003 23:23:07 GMT  
 Threading model for MTS components
Hi Assaf!
Thanx for the response. However i am still not fully satisfied with your
answer.

I wanted to know the default threading model only for those ATL that create
MTS objects.
The cause of confusion are the following lines of code that are written
after creating an
MTS component through the ATL COM AppWizard:

    val ThreadingModel = s 'Both'
(in the Registrar Script Code .RGS file)
and
     public CComObjectRootEx<CComSingleThreadModel>,          (in the Class
declarations)
and then
    #define _ATL_APARTMENT_THREADED                              (in the
StdAfx.h file)

Though I will not be using COM+ but I need to make sure what threading model
is being used, as well as what is
the best threading model in this regard. I would greatly appreciate if you
could also suggest the best way to port
the existing code into using the new threading model.

Thanx in advance.

Nadeem Rauf


Quote:
> Are you asking what the _best_ threading model would be? Or what is the
> deafult?
> The default in ATL is STA objects. If you want to take advantage of
pooling
> (MTS, COM+) you'll need to create TNA objects that aggregate the FTM.

> --
> Assaf Lavie.



> > Hi guys!

> > Can anybody please tell me what is the default threading model while
> > creating an MTS component
> > through C++ ATL COM AppWizard?

> > Is that the best threading model to pull XML from a site, transform and
> then
> > spit onto a web page?
> > Also if I need to optimize the component any further, what steps would
be
> > needed?

> > Thanx in advance.

> > Nadeem Rauf



Mon, 30 Jun 2003 23:22:48 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. Threading Model of MTS-based ATL components

2. what threading model is default when no Threading model key

3. Threading model of a component

4. About apartment thread model in ASP component..

5. About apartment thread model in ASP component..

6. CSocket problem with an Apartment threading model component !

7. COM Threading Model for ISAPI Worker Threads

8. Exe server threading model - events from worker thread question

9. VC6++: a Link error in a MTS component using ADO1.5

10. Is there any way to achieve multithreading inside MTS COM components

11. Failure to commit database inserts by child mts component

12. Holding a list within a transactional MTS component

 

 
Powered by phpBB® Forum Software