#1 2015-06-27 01:24:55

bigheart
Member
Registered: 2014-08-01
Posts: 53

Result is differ from ServiceRegister for sicShared and sicSingle

Hello!

When I execute from my code as below is OK:

//Server Side
RestServer :=  TSQLRestServerFullMemory(Model, JsonName, False, True);
RestServer.ServiceRegister(Client, [TypeInfo(IMyInterface)], sicShared);

//Client Sde
Client.ServiceRetister([TypeInfo(IMyInterface)], sicShared);

But not is OK as below

//Server Side
RestServer :=  TSQLRestServerFullMemory(Model, JsonName, False, True);
RestServer.ServiceRegister(Client, [TypeInfo(IMyInterface)], sicSingle); <=== Replace sicShared

//Client Sde
Client.ServiceRetister([TypeInfo(IMyInterface)], sicSingle);

Error message is displayed from Client Side just when above code is executed:

TServiceFactoryClient.Create(): server's IMyInterface contract differs from client's: expected["3625..."], received ["FAB6..."]

sicSingle or sicClientDriven is same result;

Only sicShared is OK.

What is the problem?

Offline

#2 2015-06-27 08:15:15

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,659
Website

Re: Result is differ from ServiceRegister for sicShared and sicSingle

Impossible to reproduce the issue.
This is tested in TTestServiceOrientedArchitecture, with no problem.

I guess there is something wrong in how you use it.

Try to check the Contract value on both sides, and find out why the ContractExpected=ContractHash values do not match.

Offline

Board footer

Powered by FluxBB