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

 


Help: OASIS Mailing Lists Help | MarkMail Help

sca-j message

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


Subject: NEW ISSUE: @AllowsPassByReference requires more detailed description


Title: NEW ISSUE: @AllowsPassByReference requires more detailed description

TARGET:

Java Common Annotations and APIs specification, section "Java Annotations" / "@AllowsPassByReference"

DESCRIPTION:

That section currently states the requirement that the callee must adhere to by-value semantics when indicating that a method of a remotable interface allows the optimization of by-reference parameter passing.

It lacks a descriptions of requirements on the caller to not modify a passed by-reference parameter during the execution of an @AllowsPassByReference method. Such concurrency situations may occur for example when

a) the caller is inherently multi-threaded and holds-on to parameters in concurrently executed threads
b) the caller is called back during an invocation of an @AllowsPassByReference method (which can happen in the same thread)

c) the @AllowsPassByReference method is in addition a @OneWay method (i.e. the caller will not wait for the completion of the actual service method)

PROPOSAL:

Discussions have not come to a conclusion so far. Here are some partial solutions and further proposals:

- allow @AllowsPassByReference for synchronous methods only (rules out problem c)
- put housekeeping responsibilities on the caller (i.e. simply be aware of of a)+b) ): promise to not change parameters between invocation and return of the method.






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