Link to home
Start Free TrialLog in
Avatar of ganeahdev
ganeahdev

asked on

WCF doubts

Sample Ex:

[ServiceContract]

    interface IContactService

    {

        [OperationContract]

        [FaultContract(typeof(EmployeeContacts))]

        EmployeeContacts GetEmpContactDetails(string txtmailID);

               

                 [OperationContract]

        [FaultContract(typeof(EmployeeContacts))]

        EmployeeContacts FetchEmplocation(string txtmailID);

 

    }

 

I have a ServiceA in which 2 methods/functionalities are written

·         Assume I have to provide services to Company-A, Company-B. How to Provide ServiceA to
          company-A with only GetEmpContactDetails functionalities access,
          even if Company-A trying to consume FetchEmplocation its  should not allow?

 

·         Do I need to create separate service account for the both company?
          Based on that shall I filter out the functionalities
          (GetEmpContactDetails, FetchEmplocation)?

 

All I want is - I don’t want to deploy separate service to
company A and companyB. I just need to use same service for
both company and pass on different functionalities
to company A and company B
Avatar of Kalpesh Chhatrala
Kalpesh Chhatrala
Flag of India image

You can provide Unique Identity to each company . User need to pass as parameter when calling WCF Api function. With that unique identity you can decide allow/restrict.
ASKER CERTIFIED SOLUTION
Avatar of Anil Golamari
Anil Golamari
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ganeahdev
ganeahdev

ASKER

Thank you..... good knowledge sharing.