none
JSON WCF over TCP (not HTTP)

    Question

  • If I want to create a WCF Service that accepts JSON (or JSON-RPC) requests over TCP (instead of HTTP), is there an easy way to do this?

    Something similar to the WebInvoke attribute (but not web =))

    Friday, November 4, 2011 3:29 PM

Answers

  • I apparently have to write a custom transport from WCF to be able to have avoid http.
    • Marked as answer by Hans E. Molin Tuesday, November 8, 2011 9:35 AM
    Tuesday, November 8, 2011 9:35 AM
  • In case anyone was thinking of doing the same thing, I ended up using Jayrock instead. Much easier.
    • Marked as answer by Hans E. Molin Monday, December 5, 2011 5:00 PM
    Monday, December 5, 2011 5:00 PM

All replies

  • this post might clear up things :) http://social.msdn.microsoft.com/Forums/en-US/wcf/thread/4c65944f-e38f-467d-afcb-7b1293d77cac/

     

    as I see, it is suggested to use string as input and output parameters for carrying serialized json objects.


    Can Bilgin
    Blog CompuSight
    Saturday, November 5, 2011 9:15 AM
  • Perhaps I'm misunderstanding the answer in that thread, but it looks like two solutions, REST service and SOAP service but I want neither.



    • Edited by Hans E. Molin Monday, November 7, 2011 1:11 PM
    • Marked as answer by Hans E. Molin Tuesday, November 8, 2011 9:35 AM
    • Unmarked as answer by Hans E. Molin Tuesday, November 8, 2011 9:35 AM
    Monday, November 7, 2011 12:46 PM
  • I apparently have to write a custom transport from WCF to be able to have avoid http.
    • Marked as answer by Hans E. Molin Tuesday, November 8, 2011 9:35 AM
    Tuesday, November 8, 2011 9:35 AM
  • In case anyone was thinking of doing the same thing, I ended up using Jayrock instead. Much easier.
    • Marked as answer by Hans E. Molin Monday, December 5, 2011 5:00 PM
    Monday, December 5, 2011 5:00 PM