Code Monkey home page Code Monkey logo

easyrpc's Introduction

EasyRpc

Adds rpc service support to AspNetCore

public void ConfigureServices(IServiceCollection services)
{
  services.AddRpcServices();
}

public void Configure(IApplicationBuilder app)
{
  app.UseRpcServices(api =>
  {
     // simple web method at /Status
     api.Method.Get("/Status", () => new { status = "Ok"});

     // Expose methods at /IntMath
     api.Expose<IntMathService>().As("IntMath");
  });
}

public class IntMathService
{
  // expose web api POST /IntMath/Add expecting {"a":int,"b":int}
  public int Add(int a, int b)
  {
    return a + b;
  }
}

Features

EasyRpc allow developers to write business related classes and host them as remote procedure calls. In essence developers focus on writing services that fullfil requirements vs. writing RESTful services that require the developer to think about which verbs they want to use.

  • Performs faster than MVC as seen in these 3rd party benchmarks
  • Services participate in Asp.Net Core dependency injection framework
  • Integrates with Asp.Net Core authorization schemes including Roles & Polices
  • Built in data context idea that can be used to fetch and save data into header
  • Filter support similar to Asp.Net filter (not exactly the same as no controller is ever created)
  • Support for request/response gzip compression, br compression
  • Built in Swagger UI

Build

Build status

easyrpc's People

Contributors

ipjohnson avatar superjmn avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.