IP Library Granted Patent US 7,346,690
Granted Patent B1
US 7,346,690 · App. 10/160,128 · Granted Mar 18, 2008

Deferred piggybacked messaging mechanism for session reuse

Assignee: Oracle International Corporation
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 7,346,690
App. No.
10/160,128
Granted
Mar 18, 2008
Kind
B1
Abstract

Described herein is a session reuse approach that reuses a session already established on a remote participant to execute an autonomous transaction. The session is reused in a manner that avoids affecting the session's state in a way adverse to later execution of the containing transaction. When beginning an autonomous transaction on a local participant, a request to initiate an autonomous transaction on a remote participant is deferred or not sent at all if the containing transaction is a distributed one. The request may be sent later, piggybacked to another message, using a piggyback messaging system. When ending an autonomous transaction, a local participant may send a request to a remote participant requesting that the remote participant commence execution of its respective containing transaction. The request is piggybacked to another message, and is thus transmitted without having to transmit the request separately, avoiding a message round trip.

Claims (56)

1. A method of managing reuse of sessions, the method comprising the steps:

preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction, wherein the step of preparing the first session state includes setting a flag to indicate whether a second session has been prepared for subsequent execution of a third transaction and a fourth transaction;

after preparing the first session state of the first session, examining said flag to determine whether the second session has been prepared for said subsequent execution by both said third transaction and said fourth transaction; and

if said second session has not been prepared, then causing a message to be transmitted which causes the preparing of the second session for said subsequent execution by both said third transaction and said fourth transaction;

wherein said first transaction and said third transaction are executed within a distributed transaction.

2. The method of claim 1 , wherein the steps further include:

terminating said second transaction;

preparing said first session state of said first session for subsequent execution of said first transaction;

wherein the step of preparing said first session state of said first session for

subsequent execution of said first transaction includes setting another flag to indicate whether the second session has been prepared for subsequent execution of said third transaction;

after preparing the first session state of the first session for subsequent execution of said first transaction, examining said other flag to determine whether the second session has been prepared for said subsequent execution of said third transaction; and

if said second session has not been prepared for subsequent execution of said third transaction, then causing another message to be transmitted which causes the preparing of the second session for said subsequent execution of said third transaction.

3. The method of claim 1 , wherein:

said first session state includes a first connection state describing a connection between processes executing within said first session and said second session; and

wherein the step of preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction includes modifying said first connection state for use by a process executing said second transaction.

4. The method of claim 3 , wherein the step of modifying said first connection state includes modifying a particular flag that indicates no transaction is currently being executed within said second session.

5. The method of claim 1 , wherein:

said first session state includes a first connection state describing a connection between processes executing within said first session and said second session; and wherein the step of preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction includes saving at least a portion of said connection state for subsequent use by a process executing said first transaction.

6. The method of claim 1 , wherein the steps further include setting, if said message is transmitted, the flag to indicate that said second session has been prepared for subsequent execution of said third transaction and said fourth transaction.

7. The method of claim 1 , wherein the steps include:

terminating said second transaction;

preparing said first session state of said first session for subsequent execution of said first transaction;

wherein the step of preparing said first session state of said first session for subsequent execution of said first transaction includes:

examining said flag to determine whether the second session was prepared for said subsequent execution of said third transaction and said fourth transaction; and

setting another flag to indicate whether the second session has been prepared for subsequent execution of said third transaction if said second session has not been prepared for subsequent execution of said third transaction.

8. The method of claim 1 , wherein the step of causing a message to be transmitted includes piggybacking a request to the message.

9. The method of claim 1 , wherein a distributed transaction includes said first transaction and third transaction.

10. The method of claim 1 , wherein said second and fourth transactions are autonomous transactions.

11. A computer-readable storage medium carrying one or more sequences of instructions for managing reuse of sessions, wherein execution of the one or more sequences of instructions by one or more processors causes the one or more processors to perform the steps of:

preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction, wherein the step of preparing the first session state includes setting a flag to indicate whether a second session has been prepared for subsequent execution of a third transaction and a fourth transaction;

after preparing the first session state of the first session, examining said flag to determine whether the second session has been prepared for said subsequent execution by both said third transaction and said fourth transaction; and

if said second session has not been prepared, then causing a message to be transmitted which causes the preparing of the second session for said subsequent execution by both said third transaction and said fourth transaction;

wherein said first transaction and said third transaction are executed within a distributed transaction.

12. The computer-readable storage medium of claim 11 , wherein the steps further include:

terminating said second transaction;

preparing said first session state of said first session for subsequent execution of said first transaction;

wherein the step of preparing said first session state of said first session for subsequent execution of said first transaction includes setting another flag to indicate whether the second session has been prepared for subsequent execution of said third transaction;

after preparing the first session state of the first session for subsequent execution of said first transaction, examining said other flag to determine whether the second session has been prepared for said subsequent execution of said third transaction; and

if said second session has not been prepared for subsequent execution of said third transaction, then causing another message to be transmitted which causes the preparing of the second session for said subsequent execution of said third transaction.

13. The computer-readable storage medium of claim 11 , wherein:

said first session state includes a first connection state describing a connection between processes executing within said first session and said second session; and

wherein the step of preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction includes modifying said first connection state for use by a process executing said second transaction.

14. The computer-readable storage medium of claim 13 , wherein the step of modifying said first connection state includes modifying a particular flag that indicates no transaction is currently being executed within said second session.

15. The computer-readable storage medium of claim 11 , wherein:

said first session state includes a first connection state describing a connection between processes executing within said first session and said second session; and

wherein the step of preparing a first session state of a first session for subsequent execution of a first transaction and a second transaction includes saving at least a portion of said connection state for subsequent use by a process executing said first transaction.

16. The computer-readable storage medium of claim 11 , wherein the steps further include setting, if said other message is transmitted, the flag to indicate that said second session has been prepared for subsequent execution of said third transaction and said fourth transaction.

17. The computer-readable storage medium of claim 11 , wherein the steps include:

terminating said second transaction;

preparing said first session state of said first session for subsequent execution of said first transaction;

wherein the step of preparing said first session state of said first session for subsequent execution of said first transaction includes:

examining said flag to determine whether the second session was prepared for said subsequent execution of said third transaction and said fourth transaction; and

setting another flag to indicate whether the second session has been prepared for subsequent execution of said third transaction if said second session has not been prepared for subsequent execution of said third transaction.

18. The computer-readable storage medium of claim 11 , wherein the step of causing a message to be transmitted includes piggybacking a request to the message.

19. The computer-readable storage medium of claim 11 , wherein a distributed transaction includes said first transaction and third transaction.

20. The computer-readable storage medium of claim 11 , wherein said second and fourth transactions are autonomous transactions.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 21, 2003
From: ORACLE CORPORATION
To: ORACLE INTERNATIONAL CORPORATION
Reel/Frame 013944/0938 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 30, 2002
From: SINHA, BIPUL; GANESH, AMIT; CHIDAMBARAN, LAKSHMINARAYANAN
To: ORACLE CORPORATION
Reel/Frame 012965/0258 →
Continuity (1)
Provisional Application 6037887500 · May 7, 2002