OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
From: Steve Swartz (steveswMICROSOFT.COM)
Date: Mon Oct 08 2001 - 10:46:09 CDT

  • Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

    If your object three and object four are standard marshaled, and are
    configured so that they run in their client's context, they will obtain
    synchronization and transactional services from their client's context.

    Since you do not pass references to your object three and object four
    out from the component that creates them (object two), then you don't
    need to worry about synchronization or transactions, since these objects
    obtain those services from their caller (that is, if object two is
    synchronized, and if object two creates and is the only caller of object
    three, then object three is synchronized by definition).

    There is no internal sharing of object instances. The only time your
    application code runs is when you call it. COM+ occasionally calls
    interfaces on your components relevant for the various services (for
    pooling or construction, say), but this should not be an issue relative
    to synchronization.

    The suggestions you have been seeing do not suggest removing the number
    of configured components per se. They suggest removing service
    configurations that are not necessary from components.

    If your threading model on VC++ components is "Both", and if you are
    creating them from out of process, then in NT/MTS they would have been
    running in the STA, whereas in W2K/COM+ they would be running in the
    MTA. If the data access objects you end up using are marked "Apartment",
    then the call from your application into the data access layer will be
    cross-apartment in W2K, whereas it is within-apartment in NT. This could
    be a significant performance problem if you're marshaling lots of data
    across the apartment boundary (which is common for data access objects
    ;)

    -----Original Message-----
    From: Charles Gamble [mailto:Charles.GambleSINGULARITY.CO.UK]
    Sent: Monday, October 08, 2001 2:43 AM
    To: DCOMDISCUSS.MICROSOFT.COM
    Subject: Re: FW: COM+ and Free Threading

    Our objects have transactional settings which means that they need
    synchronisation on. However, if we could remove the transactional
    settings
    and turn synchronisation off, would this mean that we have to perform
    our
    own thread safety mechamisms? We do not have mulithreaded clients and we
    don't share object instances between clients/other objects, so would
    this be
    necessary? Will COM+ internally share object instances in some way if
    synchronisation is off, so we are forced to do our own thread safety?
    The threading model of our objects is "Both".

    ----------------------------------------------------------------
    Users Guide http://discuss.microsoft.com/archives/mailfaq.asp
    contains important info. Save time, search the archives at
    http://discuss.microsoft.com/archives/index.html .
    To unsubscribe, mailto:DCOM-signoff-requestDISCUSS.MICROSOFT.COM