Does RemoteObjectAMF0 has concurrency problems?

January 25, 2007 at 5:31 am | Posted in amf, flex2 | 2 Comments

I have a “weird” problem in my app…

This is my test:

Server Side:
a) I have a generic pageable search service in Java (I’am using RemoteObjectAMF0 and openamf). It returns a list (a page of results) with value objects. Value Objects’ Class is determined by service params.

Client Side:
b) I have two different forms that use that search service. (Each form belongs to a different Module). Form 1 expects objects of Type A and Form 2 expects objects of Type B. Both forms are at the same time on screen
a kind of MDI…I hope so…😉
I am using cairngorm 2.1. (a command is created per event instance)

c) Some searches with Form 1 : works fine. (my pageable Datagrid is simple.. but looks fine😛 )

d) Some searches with Form 2: works fine.

e) “Parallel” search with form 1 and form 2:
Firs request of screen 1 and second request (almost parallel) of screen 2

f)Server logs are ok for both requests:
First Response : [results for form 2, only 777 objects]
2007-01-22 01:07:57,859 estimatedTotalResultsCount:777
Total Pages:4 Pagesize:200
startIndex: 0 lastIndex:199}]

Second Response : [results for form 1,  131.427 expected]
2007-01-22 01:07:57,890 estimatedTotalResultsCount:131427
Total Pages:658 Pagesize:200
startIndex: 0 lastIndex:199}]

g) Client side Brokes. It seems that “something” puts response of service 1 in service 2.
[postprocessing of object (ordering) fails, caused by “mixes(?)” of responses?? ]

This is the code of my Command:

private var recievedEvent : SearchEvent;

public function execute( event : CairngormEvent ): void {
var delegate : SearchDelegate = new SearchDelegate( this );
recievedEvent = SearchEvent( event );
delegate.search(recievedEvent.searchable.getSearchParams());
}

public function result( event : Object ) : void {
var search:Search = event.result as Search;
recievedEvent.searchable.setSearch(search);
}

h) Its a little weird problem… Search works fine individually.. but in “parallel” brokes.
– Could be a concurrency problem in service processing? (RemoteObjectAMF0)
– Could be a problem in cairngorm?
– Could be a problem in my own code?

Any Help?

(“dumb” “solution”:  Hour Glass Functionality that blocks user interaction during remote service invocation calls?  How could this “hour glass” could be implemented using RemoteObjectAMF0 ?  … I was looking some code.. and probably some classes in RemoteObjectAMF0 package must be extended….)

2 Comments »

RSS feed for comments on this post. TrackBack URI

  1. Have you found a solution to this yet? I think the project I’m working on is dealing with the same issue, and RemoteObjectAMF0 is certainly a common link in the chain.

  2. I have not found any solution for this issue…

    I was looking the code of RemoteObjectAMF0… but currently I don’t have time to debug it😦

    Currently I am avoiding concurrent calls in my app… ( sadly and tricky but “useful”…)😦

    I have post the issue in Renaun Erickson’s blog, but he didn’t post any answer…

    If you find any solution, please tell me😛


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.
Entries and comments feeds.

%d bloggers like this: