Re: use (storage)

2019-02-01 Thread Jeremy French via 4D_Tech
Hi David,

No locking occurs with "Use (Storage)” by itself.

But locking does occur for **first level** attributes of Storage.

So “Use (Storage.pref)” performs locking in other processes.

To prevent “Storage.pref” from being updated in a separate process, call:

Use (Storage.pref)
  // make modifications to pref
End Use

More details at:
https://doc.4d.com/4Dv17R3/4D/17-R3/Storage.301-3907264.en.html 
<https://doc.4d.com/4Dv17R3/4D/17-R3/Storage.301-3907264.en.html>

Best regards,
Jeremy

> On Feb 1, 2019, at 4:45 PM, David Ringsmuth via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> My test show that
> 
> Use(Storage)
> ….
> 
> Does not lock Storage.pref, and does not prevent Storage.pref from being 
> updated in a separate process.

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: use (storage)

2019-02-01 Thread Christian Sakowski via 4D_Tech
Yes, correct.

When using „use“, all operations are atomic.
--

Grüße/Regards,
[heubach-media] | Christian Sakowski
christian.sakow...@heubach-media.de
Tel: +49/(0)40/52 10 59-23




> Am 01.02.2019 um 22:45 schrieb David Ringsmuth via 4D_Tech 
> <4d_tech@lists.4d.com>:
> 
> My test show that
> 
> Use(Storage)
> ….
> 
> Does not lock Storage.pref, and does not prevent Storage.pref from being 
> updated in a separate process.
> 
> By lock, I mean that during use(Storage) in process A, use(Storage.pref) in 
> process B will execute without waiting.
> 
> By update I mean that Storage.pref.test can be updated in process B when 
> Storage is locked in process A.
> 
> I just want to make sure that Storage and it’s shared objects are intended to 
> be used this way.
> 
> The documentation does not show examples of this.
> 
> The point is that locking should occur at the parent of the property being 
> updated, not unnecessarily at the top level.
> 
> Is that correct?
> 
> Thanks!
> 
> David Ringsmuth
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **


--
heubach media
Osterfeldstr. 12-14 | Haus 1 | Eingang Nord
22529 Hamburg
tel: 040 / 52 10 59 - 10 | fax: -99
mail: i...@heubach-media.de
home: www.heubach-media.de
Geschäftsführer|CEO: Matthias Heubach

Mieten Sie Ihre Computer, iPads & Drucker für Ihre Events bei:
http://www.milo-rental.com

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen.
Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten 
haben,
informieren Sie bitte sofort den Absender und vernichten Sie diese Mail.
Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist nicht 
gestattet.
 
This e-mail may contain confidential and/or privileged information.
If you are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail.
Any unauthorized copying, disclosure or distribution of the
material in this e-mail is strictly forbidden.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**