简体   繁体   中英

Need To Link OData Service with other OData Service

I have this scenario. I have two servers and one client DB server :

  1. server 1

  2. server 2

  3. client server

client server can only see server 2 and server 2 can only see server 1 and server 1 can only see DB Server

Client server need to connect to odata service that inside server1 so I need to create new odata inside server 2 read from odata from server1

public class WcfDataService1 : DataService<Remote odata >
{
   public static void InitializeService(IDataServiceConfiguration config)
   {
      config.SetEntitySetAccessRule("*", EntitySetRights.All);
   }
}

what is the easiest way to implement this scenario?

You may setup a proxy on server 2. The proxy accepts the requests from the client server and forwards them to server 1.

If you are using IIS, you can reference this: https://serverfault.com/questions/47537/can-iis-be-configure-to-forward-request-to-another-web-server

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM