Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 364635 - 3rd party service invocations are broken for services that use JSON, form data, or NONE for the request/response format.
Summary: 3rd party service invocations are broken for services that use JSON, form dat...
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P1 critical (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-23 13:01 EST by Joseph Vincens CLA
Modified: 2017-02-23 14:20 EST (History)
4 users (show)

See Also:


Attachments
patch (3.55 KB, patch)
2011-11-23 13:19 EST, Joseph Vincens CLA
lasher: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Vincens CLA 2011-11-23 13:01:33 EST

    
Comment 1 Joseph Vincens CLA 2011-11-23 13:19:57 EST
Created attachment 207440 [details]
patch
Comment 2 Joseph Vincens CLA 2011-11-23 13:25:00 EST
When Paul made the change for 362322 he had no way of knowing he needed to change CallStatementTemplate because CallStatementTemplate only had code for an Expression. 

In 362322 Paul said: I have updated the following classes to remove the extraneous checking
for Enum and Expression annotion values:
....
org.eclipse.edt.gen.javascripot.annotation.templates.XMLValueTemplate


CallStatementTemplate is expecting an Expression which Paul removed XMLValueTemplate. 
My proposed change will use the code that Paul left in XMLValueTemplate. Since it is the exact same code for both, I re-factored it into EnumerationEntryTemplate.genRuntimeTypeName and am calling it from XMLValueTemplate and CallStatementTemplate. The attached patch is the proposed change.
Comment 3 Brian Svihovec CLA 2011-11-23 16:31:30 EST
Joe, thanks for putting this patch together on such short notice.

Would it make sense to leave in the check for expression in ServicesCallStatementTemplate.java, and then remove that check after .7?
Comment 4 Will Smythe CLA 2011-11-23 16:47:21 EST
I applied the patch and was able to get a couple of external sample JSON services to work. Without the patch, neither service worked. Good find/fix!
Comment 5 Joseph Vincens CLA 2011-11-23 20:02:21 EST
Per Brian's comment I added the  else if(Expression) and retested. I had removed this based on Paul's comment that it was not needed. Since the code already had an if(Expression) changing it to an else if(Expression) won't hurt.
Comment 6 Joseph Vincens CLA 2011-11-28 07:39:37 EST
verified