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

Add one more way to call RPC #59

Open
LeKovr opened this issue Aug 14, 2018 · 0 comments
Open

Add one more way to call RPC #59

LeKovr opened this issue Aug 14, 2018 · 0 comments

Comments

@LeKovr
Copy link

LeKovr commented Aug 14, 2018

I'm going to use RPC inside golang code without knowledge about method's argument structure at compile time (inside templates). It is based on method name in string and map[string]interface{} for request arguments.
I guess there are 3 ways to get wanted:

  1. reinvent gorilla/rpc's map.go in another package without JSON decoding
  2. fork gorilla/rpc and make public all of service and serviceMethod structs
  3. fork gorilla/rpc and add tiny (33 lines) function with signature like func (s *Server) Call(r *http.Request, decoder func(input interface{}, output interface{}) error, method string, args *map[string]interface{}) (interface{}, error)

What would you advise?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

2 participants