[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: quick question on threads & remote stubs
- To: "Reason" <reason@exratio.com>, "Reason" <reason@exratio.com>,<ozone-users@ozone-db.org>
- Subject: Re: quick question on threads & remote stubs
- From: Falko Braeutigam <falko@smb-tec.com>
- Date: Sun, 1 Apr 2001 16:44:31 +0200
- Delivered-To: softw7-ozone-db:org-ozone-users@ozone-db.org
- In-Reply-To: <000701c0ba3c$bd89c260$127eafd8@exratio>
- Organization: SMB
- References: <000701c0ba3c$bd89c260$127eafd8@exratio>
On Sun, 01 Apr 2001, Reason wrote:
> If two separate threads within the same JVM call
> ExternalDatabase.objectForName(name), do they receive references to the same
> stub object or to two different stub objects? In other words, does each
> different thread within a single JVM requesting an interface to the same
> persistant object require the creation of a new stub?
Yes, each subsequent call of objectForName, regardless if this is in the same
or a different thread, creates and returns a new proxy object. proxy objects
are very small (6 bytes) so this should not be a problem. An object cache could
help to reduce the number of proxy objects in the VM but this would also add an
extra overhead to search in the cache each time a proxy is created.
Falko
--
______________________________________________________________________
Falko Braeutigam mailto:falko@smb-tec.com
SMB GmbH http://www.smb-tec.com