V4RB 351 Var Char Error

Cindy Brown cindy at kowhaiprogramming.com
Wed Dec 3 20:45:17 CST 2003


Thanks Ruslan. I'll take a look at this and see what I come up with.

> on 12/3/03 3:25 AM, Cindy Brown at cindy at kowhaiprogramming.com wrote:
> 
> Hi Cindy,
> 
>>> So I think problem really can come from your threading model.
>>> Please make sure that you use semaphores AT LEAST when you do modifications
>>> of records in Valentina db + flush.
>> 
>> Every time a record is added, edited or deleted on the server, the db calls
>> Flush. If two or more threads call flush at the same time, will that affect
>> the server? Or if flush happens too quickly one after the other, will that
>> also cause problems?
> 
> This CAN AFFECT PROBLEM in the __preemptive__ threads but not in cooperative
> threads.
> 
> 
> In the cooperative threads on the MacOS classic YOUR call to Valentina
> plugin never return until it finishes. So there was no need for any
> protection.
> 
> I have hear that REALbasic for own code produce preemptive threads.
> 
> By logic, if you write in REALbasic code, and you know that they are
> preemptive, you SHOULD use ONE global mutex to access Valentina
> 
> 
>   valentina_mutex.Lock
> 
>       sqlExecute
>       flush
> 
>   valentina_mutex.unlock
> 
> 
> We use the same now inside of Valentina server alpha, until it is based on
> 1.x kernel.
> 
> 


-- 

Cindy Brown
Programmer
SchoolMaster

Kowhai Programming Systems
PO Box 198, Invercargill
81 Marama Avenue South, 9RD Invercargill
Phone (03) 213 1243
Fax (03) 213 1248
Mobile (021) 354 930
<http://www.kowhaiprogramming.com/>




More information about the Valentina mailing list