Subject | Re: [Firebird-Architect] RFC: External Engine API |
---|---|
Author | Adriano dos Santos Fernandes |
Post date | 2007-12-10T16:45:21Z |
Vlad Khorsun escreveu:
special TPB? Leak the handle?
Adriano
>> We create a method Attachment::startTransaction...Transaction*
>>
>
> And it would return ... what ?
>
>FWIW, it requires TLS lookup in TDBB to get the handles.
>
>>>> AFAIU, this requires TLS.
>>>>
>>>>
>>> It is implemented in B2_1_ExecStmt branch and not requires TLS.
>>>
>>>
>> I didn't reviewed it yet. Do it means something is passed in the DPB/TPB?
>>
>
> I implemented Alex's idea - Y-Valve passed its attachment\transaction handles
> into lower level just after its creation and asked lower level for this handles when
> needed. Two new internal API entries make the job GDS_SET_PUBLIC_HANDLE
> and GDS_GET_PUBLIC_HANDLE. It is implemented by jrd8 subsystem only.
> At jrd8 level passed handles is stored within corresponding objects -
> Jrd::Attachment::att_public_handle and Jrd::jrd_tra::tra_public_handle
>
>> I suppose COMMIT/ROLLBACK in the server could work with savepoints, toAnd what components should do with user's transaction obtained via
>> not change user transaction.
>>
>
> Savepoint is not a transaction. It would be confusion if the same code working
> with current context would start\finish savepoint but would start\finish transaction,
> if working within own context. If user code needs savepoint it can create it explicitly.
special TPB? Leak the handle?
Adriano