Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 10 of 10 total
Thread Semaphore Locks
Wed, Oct 4 2006 11:10 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

Will ElevateDB still have semaphore locks? If not I need to start thinking about controlling concurrent users.

Roy Lambert
Wed, Oct 4 2006 5:12 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< Will ElevateDB still have semaphore locks? If not I need to start
thinking about controlling concurrent users. >>

No, it won't have semaphore locks, but it does have options to control the
number of concurrent sessions on a given database (specified when the
database is created) and/or application configuration file (specified via
the TEDBEngine component).  One is a subset of the other, and both work with
remote C/S *and* local sessions.

--
Tim Young
Elevate Software
www.elevatesoft.com

Wed, Oct 4 2006 5:50 PMPermanent Link

"Terry Swiers"
Tim,

> No, it won't have semaphore locks, but it does have options to control the
> number of concurrent sessions on a given database (specified when the
> database is created) and/or application configuration file (specified via
> the TEDBEngine component).  One is a subset of the other, and both work
> with remote C/S *and* local sessions.

So if you create two separate TEDBSession objects and connect to the same
database, this will count as 2 sessions or just 1 because it's from the same
instance of the engine?

--

---------------------------------------
 Terry Swiers
 Millennium Software, LLC
 http://www.1000years.com
 http://www.atrex.com

 Atrex Inventory Control/POS -
    Big business features without spending big business bucks!

Atrex Electronic Support Options:
 Atrex Knowledgebase: http://www.atrex.com/atrexkb.asp
 Email: mailto:support@atrex.com
 Newsgroup: news://news.1000years.com/millennium.atrex
 Fax: 1-925-829-1851
 Phone: 1-925-828-5892 (M-F, 9a-5p Pacific)
 ---------------------------------------

Thu, Oct 5 2006 3:04 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim


The next question is ... does that make it easier or more difficult for me <vbg>

Roy Lambert
Thu, Oct 5 2006 4:16 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Terry,

<< So if you create two separate TEDBSession objects and connect to the same
database, this will count as 2 sessions or just 1 because it's from the same
instance of the engine? >>

It will count as 2 sessions.

--
Tim Young
Elevate Software
www.elevatesoft.com

Thu, Oct 5 2006 4:17 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< The next question is ... does that make it easier or more difficult for
me <vbg> >>

It is supposed make it easier, but I may be wrong. Smiley

--
Tim Young
Elevate Software
www.elevatesoft.com

Fri, Oct 6 2006 10:43 AMPermanent Link

Sean McCall
Tim,

How hard would it be to add an optional text property to the session
component that would be stored on the server and available to all logged
in sessions. I'll call it SessionTag. It could be used for a GUID
generated when the app starts up, a user ID, or even to store a bunch of
info just like an .INI file. With functions to return the server
SessionTagCount & SessionTag[AIndex] these would be an easy way to track
 users or anything else one could imagine. A specialized function
UniqueSessionTagCount would be a great shortcut to tell exactly how many
users are logged into the server provided the SessionTag contained only
a user identifier.

Sean

Tim Young [Elevate Software] wrote:
> Terry,
>
> << So if you create two separate TEDBSession objects and connect to the same
> database, this will count as 2 sessions or just 1 because it's from the same
> instance of the engine? >>
>
> It will count as 2 sessions.
>
Fri, Oct 6 2006 4:31 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Sean,

<< How hard would it be to add an optional text property to the session
component that would be stored on the server and available to all logged in
sessions. I'll call it SessionTag. It could be used for a GUID generated
when the app starts up, a user ID, or even to store a bunch of
info just like an .INI file. >>

ElevateDB already has a SessionDescription property that is associated with
each SessionName and can be populated with any information that you want.

<< With functions to return the server SessionTagCount & SessionTag[AIndex]
these would be an easy way to track users or anything else one could
imagine. A specialized function UniqueSessionTagCount would be a great
shortcut to tell exactly how many users are logged into the server provided
the SessionTag contained only a user identifier. >>

You could do so with a stored procedure that included a SET statement like
this:

SET SessionCount=SELECT Count(*) FROM ServerSessions WHERE Name='MyTag';

OR

SET SessionCount=SELECT Count(*) AS SessionCount FROM ServerSessions WHERE
Description='MyTag';

where SessionCount is an OUT parameter to the stored procedure.
ServerSessions is a special configuration table that is populated with the
current server session information.

--
Tim Young
Elevate Software
www.elevatesoft.com


Mon, Oct 9 2006 8:38 AMPermanent Link

Sean McCall
Excellent!

Tim Young [Elevate Software] wrote:
> Sean,
>
> << How hard would it be to add an optional text property to the session
> component that would be stored on the server and available to all logged in
> sessions. I'll call it SessionTag. It could be used for a GUID generated
> when the app starts up, a user ID, or even to store a bunch of
>  info just like an .INI file. >>
>
> ElevateDB already has a SessionDescription property that is associated with
> each SessionName and can be populated with any information that you want.
>
> << With functions to return the server SessionTagCount & SessionTag[AIndex]
> these would be an easy way to track users or anything else one could
> imagine. A specialized function UniqueSessionTagCount would be a great
> shortcut to tell exactly how many users are logged into the server provided
> the SessionTag contained only a user identifier. >>
>
> You could do so with a stored procedure that included a SET statement like
> this:
>
> SET SessionCount=SELECT Count(*) FROM ServerSessions WHERE Name='MyTag';
>
> OR
>
> SET SessionCount=SELECT Count(*) AS SessionCount FROM ServerSessions WHERE
> Description='MyTag';
>
> where SessionCount is an OUT parameter to the stored procedure.
> ServerSessions is a special configuration table that is populated with the
> current server session information.
>
Mon, Oct 9 2006 2:32 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Sean,

<< Excellent! >>

Actually, it's easier than even using a stored procedure.  You could simply
just issue the query directly:

SELECT Count(*) FROM ServerSessions WHERE Name='MyTag'

using a TEDBQuery.

--
Tim Young
Elevate Software
www.elevatesoft.com

Image