[arquillian-issues] [JBoss JIRA] (ARQ-1400) Failure to create Enrichment hidden by Client Assertion

Aslak Knutsen (JIRA) jira-events at lists.jboss.org
Fri Jun 7 08:14:54 EDT 2013


    [ https://issues.jboss.org/browse/ARQ-1400?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12780116#comment-12780116 ] 

Aslak Knutsen commented on ARQ-1400:
------------------------------------

{code}
aslak> lfryc https://github.com/arquillian/continuous-enterprise-development/blob/rel_rest/code/application/web/rest/relation/src/test/java/org/cedj/geekseek/web/rest/relation/test/RelationResourceTestCase.java
<aslak> tight.. i degraded warp. let me try latest again
<aslak> it's caught in DefaultHttpRequestEnrichmentService.enrichRequest
<aslak> java.lang.IllegalStateException: java.io.NotSerializableException: org.cedj.geekseek.domain.relation.test.model.SourceObject
<aslak> but i can't see it anywhere exposed
<aslak> i see the Assertion error from my code and nothing in the log
<lfryc> aslak: Warp tries to wrap all exceptions and propagate them as a test failure
<lfryc> +1 it could actually print the stack trace
<lfryc> because sometimes more than one side fails.. client/proxy/server

<aslak> DefaultWarpRequestSpecifier.execute()
<aslak> executeWarp.fire(new ExecuteWarp(activity, warpContext));
<aslak> if that line throws an exception, e.g. a Assertion exception (due to the Interspection not being called), then the real cause is hidden
<aslak> if i remove the Assertion exception i can see the original

<lfryc> looking..
<lfryc> aslak: which Assertion exception you are talkinga bout?
<lfryc> it's thrown by you or Warp?
<aslak> me
<aslak> from inside Activity
<lfryc> ic
<lfryc> hmm
<lfryc> the logic should be:
<lfryc> I say "should" because I refactored that way and it's tested that way.. :-)
<lfryc> ... when server fails, then it should be propagated (client exception should be swallowed)
<lfryc> ... when proxy fails, then it should behave same as server
<lfryc> cause when client fails, it's usually because of reaction to server's failure
<lfryc> so let's propagate it first (instead of chaining those issues or so)
<lfryc> so you are saying..
<lfryc> if serialization fails (on a proxy)..
<lfryc> then client fails and its exception is propagated instead of showing proxy's exception ?

<lfryc> aslak: ^
<lfryc> https://github.com/arquillian/arquillian-extension-warp/blob/master/impl/src/test/java/org/jboss/arquillian/warp/impl/client/execution/TestDefaultWarpExecutor.java#L75

<aslak> in this case it's Client fails due to reactions to Server failure because Proxy failed on client and never arrived at server
<aslak> and i get the client failure
<aslak> it fails to create the enriched request, but the request still goes trough
<aslak> i think the actual Request should be stopped if the enrichment fails
<lfryc> ah, ic
<lfryc> yeah, that make sense
{code}

                
> Failure to create Enrichment hidden by Client Assertion
> -------------------------------------------------------
>
>                 Key: ARQ-1400
>                 URL: https://issues.jboss.org/browse/ARQ-1400
>             Project: Arquillian
>          Issue Type: Feature Request
>      Security Level: Public(Everyone can see) 
>          Components: Extension - Warp
>    Affects Versions: warp_1.0.0.Alpha2
>            Reporter: Aslak Knutsen
>
> The chain of event are:
> * Activity is executed
> * Client Request fail to enrich
> * Request goes to server
> * Response comes back
> * Client asserts the Response and fail
> * Exception shown to user is the failed Client side Assertion.
> The real cause of the failure is the failed serialization of the enrichment object to setup the server side, which cause the server side response to be wrong and client assertion of course failing.
> Two things odd here:
> * Enrichment problems are hidden
> * Request still goes to server even tho we couldn't fulfill the setup

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the arquillian-issues mailing list