Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Operation output #15

Merged
merged 2 commits into from
Jul 3, 2013
Merged

Operation output #15

merged 2 commits into from
Jul 3, 2013

Conversation

leoping
Copy link

@leoping leoping commented Oct 12, 2012

This pull request addresses two issues:

  1. Fixed bug where the fallback logic for operation's input message type was not correct (it was looking at operation_name instead of port_mesage_type). For example, see fixed specs where it was (incorrectly) identifying "sendsms" as the input name, instead of the correct "sendsmsRequest".
  2. Included operation's output to the operations hash, to be consistent with the already-included operations input.

We have tested our changes against the wasabi specs, as well as the specs of savon and savon-multipart, and they all pass (on a local test machine). We will look into the Travis build report ASAP.

Leo Ping added 2 commits October 11, 2012 17:22
…tion's input message type was not correct. Also added operation's output for each operation.
@egilburg
Copy link

Hi, this is a co-worker of leoping. I looked at the Travis build and it seems to be passing on all platforms except jruby, which fails with a gem install error (nokogiri). Since we haven't changed any gem dependencies in our pull request, we are not sure why this is happening or how to fix it, but it seems to not be related to our changes.

@timabdulla
Copy link
Member

hm. that's a strange reason for failure. i'll investigate further when i have a chance.

@timabdulla
Copy link
Member

@rubiii - do you think that the operation output should be included in the return value of operations? i believe that this would actually be quite useful.

@timabdulla
Copy link
Member

that said, i'm not sure that i agree with the implementation of the feature in this PR.

@rubiii
Copy link
Contributor

rubiii commented Jan 10, 2013

@timabdulla well, basically the code was moved from input_for to input_output_for, right?
are you talking about the second argument for that method?

i'm not sure whether this new piece of information can be used to improve savon, but it looks like a nice addition.

@leoping
Copy link
Author

leoping commented Jan 11, 2013

Thanks @timabdulla and @rubiii for looking into this PR, and thanks @timabdulla for investigating the failed Travis build for jRuby. @timabdulla, could you please provide a bit more details on your comments about not agreeing to the implementation of the feature at your earliest convenience? We'll be glad to make any changes if necessary. Thanks!

@rubiii
Copy link
Contributor

rubiii commented May 11, 2013

this should be fixed on master. sorry that this took me so long. i updated the changelog to reflect the changes on master. if you would like to test the new code before the release, please give it a try and let me know if it works for you. it's probably still weeks until 4.0.0, but the sooner i can get feedback, the better. thanks.

@leoping
Copy link
Author

leoping commented May 17, 2013

Thanks @rubiii. We'll test the new code asap and let you know.

@alvinj01
Copy link

@rubiii We cannot test Wasabi 4.0.0 because we also need a version of Savon that uses Wasabi 4.0.0. Is there something else that we can work with?

rubiii added a commit that referenced this pull request Jul 3, 2013
@rubiii rubiii merged commit 8413ba8 into savonrb:master Jul 3, 2013
@ghost ghost assigned rubiii Jul 3, 2013
@rubiii
Copy link
Contributor

rubiii commented Jul 3, 2013

hey @leoping,

my plans for savon version 3 changed to not use wasabi, but to include the code for the new parser into savon. since savon version 2 will keep using wasabi, i merged your changes and i'm planning to release them with savon v2.3.0.

hope you can test your app against wasabi master (and the savon version2 branch) if you can.

@leoping
Copy link
Author

leoping commented Jul 5, 2013

Thanks @rubiii! We'll test our code with savon version2 branch and wasabi master and let you know. For Savon version 3, what do you mean by "include the code for new parser into savon"? Which new parser are you referring to? Thanks.

@leoping
Copy link
Author

leoping commented Jul 5, 2013

@rubiii, nvm, i guess you mean a new parser similar to lib/wasabi/parser.rb right?

@rubiii
Copy link
Contributor

rubiii commented Jul 5, 2013

right. savon master is what will become savon version 3. if you look at the code, you can see that it doesn't depend on wasabi any longer, but ships with all the code i've been working on for wasabi 4.

This was referenced Jul 20, 2013
@paracycle
Copy link

I think part of this patch caused a regression in Savon. The first item in the list of the original PR message is not valid. The name of the operation (and thus the message_tag) should be read from operation[@name] and not from input[@message].

With this patch the behaviour of Savon is not inline with other tools (for example SoapUI).

For reference, see my comments in savonrb/savon#520.

Thus either this patch should be partially rolled back, or Savon should implement a different logic when deciding on the message tag name.

@tjarratt
Copy link
Contributor

tjarratt commented Dec 9, 2013

I'm looking into this issue now. My current thoughts are that @paracycle's analysis is spot on, and that we'll need to revert this issue and figure out which part of this PR caused the regression in Savon.

tjarratt added a commit that referenced this pull request Dec 9, 2013
@paracycle was kind enough to track down these changes. I believe these changes
may be valid for Output, but almost certainly not for Input.

I had an opportunity to speak with @rubiii earlier about this and his thoughts
were that it wasn't very surprising that this change broke a lot of real code.
For one, it also changed specs. Secondly, there wasn't a real example of why this
would need to be like this in the PR. Lastly, the end result of the code is
overly complicated. I've just spent the last hour looking at the `input_output_for`
method in Wasabi::Parser just to find out that this was pulling in a completely
bogus request / response tag name in two thirds of the cases.

My hopes are that this fix will fix the regression in Savon 2.3.x and we can
stop worrying about this for Savon v3.
leoping pushed a commit to leoping/wasabi that referenced this pull request Dec 16, 2013
@coveralls
Copy link

Coverage Status

Coverage remained the same when pulling 8413ba8 on Sage:operation_output into e080f40 on savonrb:master.

tjarratt added a commit that referenced this pull request May 27, 2014
There's a lot of convoluted logic going on in Wasabi for determining the
"correct name" for an operation. Around this time in 2013, a change in PR #15
that made the parser fall back to the port message's message attribute.

I searched around in the W3 spec for where this is the correct behavior and all
I could find was hints that the operation name should always be used.

Unsure if and or when this will ever be determined correctly, but this seems
to be a step in the right direction.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

8 participants