I have a wcf service in 1 project and an object model that holds all my objects in another project. I add a reference to the object model in the service project and am able to use the objects in my service without incedent.
When I publish the service and other users use it. They are able to enter invalid data and schema and the service does Not fail.
I need the service to be connected to the object model. If users to not adhere to the schema of the objects the service should fail automatically.
Im am not sure if maybe I have to set a configuration maybe in the web.config?
What I am not understanding is if I set a property on an object to required. If the user does not add this property to the object being passed to the service why isnt the service automatically stopping?
[DataMember(IsRequired = true)]
public string VendorName { get; set; }