This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 84900 - Test run failure for correlation ID collision could be better
Summary: Test run failure for correlation ID collision could be better
Status: VERIFIED FIXED
Alias: None
Product: soa
Classification: Unclassified
Component: JBI Test Driver (show other bugs)
Version: 5.x
Hardware: All All
: P2 blocker (vote)
Assignee: Jun Qian
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-14 13:51 UTC by Michael Frisino
Modified: 2007-09-28 00:17 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Frisino 2006-09-14 13:51:59 UTC
The user genarlly assumes that every test run for a given test case will result
in a new process instance. However, if the process is set up to use content
based correlation then the corellation id may be embedded in the input.xml. If >
1 request with this input.xml is sent to runtime then only the first will result
in process instance and subsequent requests will fail "Error Not Completed
Details <Concurrent test thread > 0> did not complete"

The question is, is that the best we can do to help the user understand why the
test run failed? Is there no way to indicate test failed because there was
already an instance running with the same correlation id as the requested by
test run?
Comment 1 Michael Frisino 2006-09-14 13:52:42 UTC
note, i assigned this to test driver but may actually be a runtime RFE.
Comment 2 Michael Frisino 2006-09-14 13:58:21 UTC
FYI - the way to reproduce this easily is to use the TravelReservationService
sample. This uses content based correlation.

The correlation is based on properyt alias set up in wsdl. 
The input.xml messages have special element that is used for this purpose.


		<TravelItinerary xmlns="http://www.opentravel.org/OTA/2003/05">
			<ItineraryRef Type="14" ID="M839LW">			
				<UniqueID>M839LW</UniqueID>
			</ItineraryRef >

You can see the UniqueID elemnent. That is used for correlation.
If you run > 1 of the test cases in quick succession (or more easily, if you run
two test runs while in Debug mode and stopped at breakpoint) you will trigger
the correlation problem that this bug refers to. 

Comment 3 Venkat Chellasamy 2006-09-23 00:07:39 UTC
Can you look at how best to propagate the error or throw appropriate fault in 
this situation?

This may not be possible for this release, changing to enhancement request.

[#|2006-09-22T15:36:59.492-0700|SEVERE|sun-appserver-
pe9.0|com.sun.jbi.component.com.sun.bpelse-1.0-
2com.sun.jbi.engine.bpel.core.bpms.bpelImpl.runtime.BPELInterpreter|_ThreadID=6
5;_ThreadName=BPELSEInOutThread8;_RequestID=17686b5f-77ab-4dcf-b3ef-
582c75d5216e;|Exception occured while executing a business process 
instance.            
com.sun.jbi.engine.bpel.core.bpel.exception.CorrelationAlreadyExists: An 
instance is associated with the correlation
Comment 4 Michael Frisino 2006-09-23 14:08:56 UTC
Venkat, I disagree that this is an RFE. At best it is a bug that will have to be
waived. Users expect that runtime faults that are not handled by the BPEL
process itself  will be propagated back to requester. 

If this is not "fixable" it should be waived, but I don't see it as an RFE
unless someone can explain why it would not be considered fundamental behavior.

Comment 5 Jun Qian 2006-09-23 18:44:28 UTC
What if we make sure that two instances of the same test case cann't be ran at
the same time in the test driver, say, by disabling the test case's Run action
until the previous run finishes? This won't work, of course, if two different
test cases use the same correlation ID by accident.
Comment 6 Michael Frisino 2006-09-26 10:54:08 UTC
if waived this should be documented in Developer Guide trouble shooting section.
Comment 7 Alexei Mokeev 2007-02-16 10:06:01 UTC
Added EP551_WAIVER_REQUEST keyword according to request from Gabe:
Explanation: BPEL engine needs to send a fault in this case instead of throwing
the exception. It will only happen in limited cases with correlation when a
certain timing is involved 
Comment 8 Alexei Mokeev 2007-02-19 07:01:07 UTC
No Objections in 48 hours. Waived.
Comment 9 Alexei Mokeev 2007-03-05 17:27:46 UTC
Removed Beta EP551_WAIVER_APPROVED keyword - we are going forward to FCS.
Comment 10 Sergey Lunegov 2007-07-19 14:24:30 UTC
Venkat, please address this bug.
Comment 11 Jun Qian 2007-08-20 20:33:18 UTC
After discussion with Venkat, we agreed that this is a user error. The user should not run multiple correlation tests
with the same correlation ID at the same time. 

That said, the test driver has been improved to help a scenario like this. The same test case now can't be run more than
once at the same time. 

Please note that the user can still run into this problem if she decides to run two test cases with the same correlation
ID at the same time. This should probably be documented.
Comment 12 pchen 2007-09-28 00:17:13 UTC
Using build 200709271200 on WinXP

I was able to verify that a test case cannot be run twice at a time.
I get the following message:

  The following test case(s) are skipped because they are in progress: [NewTestcase]