OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

sca-c-cpp message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [sca-c-cpp] NEW ISSUE: Preserving State of C components.



This issue has been assigned id CCPP-43 in the Jira system.
See
http://www.osoa.org/jira/browse/CCPP-43.

Bryan Aupperle, Ph.D.
STSM, WebSphere Enterprise Platform Software Solution Architect
Master Inventor

Research Triangle Park,  NC
+1 919-254-7508 (T/L 444-7508)
Internet Address: aupperle@us.ibm.com



Bryan Aupperle/Raleigh/IBM@IBMUS

08/19/2008 02:43 PM

To
sca-c-cpp@lists.oasis-open.org
cc
Subject
[sca-c-cpp] NEW ISSUE: Preserving State of C components.






TARGET: C++ C&I Spec

DESCRIPTION: Section 2.3.4 of the C spec discusses the possibility of passivating a service implementation instance in a long-running conversation, however it doesn't define how implementation state should be preserved.

PROPOSAL:   This is a initial view of a possible set of APIs to provide this functionality.

A component that needs to have state maintained requests the space it needs from the SCA runtime SCAStateAlloc() and can access the persistent state with SCAGetState().  SCAStateAlloc() returns a block of memory that will associated with the requesting component instance for the rest of the instance’s lifecycle.  The component uses this memory for all relevant state data.  If a component instance might be passivated, it is considered best practice to call SCAGetState() to endure a valid pointer before accessing any persistent data.  If a component is implemented as a program, SCAGetState() can be called on any invocation of an operation of a service of the component as needed.

void SCAStateAlloc(int bytesNeeded,
                  void **stateBuffer

                  int *compCode,

                  int *reason);


void SCAGetState(void **stateBuffer

                int *compCode,

                int *reason);


Bryan Aupperle, Ph.D.
STSM, WebSphere Enterprise Platform Software Solution Architect


Research Triangle Park,  NC
+1 919-254-7508 (T/L 444-7508)
Internet Address: aupperle@us.ibm.com



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]