Changes between Initial Version and Version 1 of Ticket #6548, comment 4


Ignore:
Timestamp:
Jun 20, 2016, 7:31:56 PM (8 years ago)
Author:
glindsay

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #6548, comment 4

    initial v1  
    22> It would be better if you could configure the connection lifestyle explictly e.g transient, singleton or thread (e.g using a reference counter), so that the end user has complete control over when connections are open and closed.
    33
    4 After experimenting with the code, the major issue I found in trying implement a lifestyle type paradigm is that datasets are created and closed sequentially and there appears no way of keeping knowing when a thread has finished processing requests. Eg if you increment a reference counter when a connection is opened and then decrement on close (through the dataset destructor) the connections never get shared as the reference counter never goes above 1.
     4After experimenting with the code, the major issue I found in trying implement a lifestyle type paradigm is that datasets are created and closed sequentially and there appears no way of knowing when a thread has finished processing requests. Eg if you increment a reference counter when a connection is opened and then decrement on close (through the dataset destructor) the connections never get shared as the reference counter never goes above 1.
    55
    66