How can we improve WCF Data Services?

Auto generate methods on the client to call service operations

I have a service operation defined on my service that is exposed via the metadata. When I use the Add Service Reference gesture to create client proxy code, the proxy code should include methods that call those service operations (for instance, if I have a service operation with the signature "IQueryable<Customer> GetCustomerByCity(string city)", I should have a corresponding client method that calls that service operation and materialized the result

500 votes
Vote
Sign in
(thinking…)
Password icon
Signed in as (Sign out)
You have left! (?) (thinking…)
Mike Flasko shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →
planned  ·  Mark Stafford responded  · 

While this ask is purely a feature ask, we currently do not generate methods on the client to call service operations. As part of the OData v4 client library, we plan to modify our code generation from using CodeDom to a T4 template. Best case scenario, in the same time frame we will make that T4 template publicly available and anyone can modify it to their heart’s content. Worst case scenario, we will either add this feature ourselves down the road or make the T4 template public as soon as we can.

7 comments

Sign in
(thinking…)
Password icon
Signed in as (Sign out)
Submitting...
  • Anonymous commented  ·   ·  Flag as inappropriate

    Yes, please add this feature - it's such a common scenario, it will save many VS users a lot of time & reduce the possibility of human error in a tricky area.

  • Anonymous commented  ·   ·  Flag as inappropriate

    This feature is very much needed since every time I add or modify my service, I have to manually generate proxy .cs and webreference file, copy it to the solutions directory and proceed. Very time consuming and cumbesome experience.

  • dfgdfgdfg commented  ·   ·  Flag as inappropriate

    it is a big shame for Microsoft that they missed this feature. Abslolutely mandatory!

  • Dave Kerr commented  ·   ·  Flag as inappropriate

    I cannot agree more, it would be very helpful to generate proxies for all service operations.

Feedback and Knowledge Base