Love all, trust a few, do wrong to none.
Suppose that I have 4 client socket threads. Someone swiped at terminal 1, client socket 1 reads the data and tries to insert a record in database, at the same time if another person swipes at other terminal say 2 or 3 or 4 the appropriate client socket will receive the data and tries to insert a record in database.Session interface
The Session interface is the primary interface used by Hibernate applications. An
instance of Session is lightweight and is inexpensive to create and destroy. This is
important because your application will need to create and destroy sessions all the
time, perhaps on every request. Hibernate sessions are not threadsafe and should
by design be used by only one thread at a time.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Now suppose XYZ swipes at terminal1, thread1 will read and hand over the data to session1. Since the outtime in session1 is null, the outtime will be noted. Whereas this time XYZ is inside the school.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Love all, trust a few, do wrong to none.
Here. Have a potato. I grew it in my armpit. And from my other armpit, this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|