Required schema fields block updates

Matthew Clark 9 years ago updated by anonymous 6 years ago 2

If an adapter has a field marked as required, all update attempts fail validation. I have recreated this with a chris21 composite adapter, and a singular CSV adapter. The following errors appear in the logs and the second is thrown back to FIM:

25/May/2012 15:08:40 Warning
Adapter The entity <null> (60b62d76-d1cd-419a-8ed2-9fb864450855) in the connector CSV Test (a20d54cf-20c6-4583-bfe9-4df697c3d575) failed validation 1 times for the following reasons: Key is a required field and is not present.
25/May/2012 15:08:40 Warning
Adapter Adapter request to update entity to adapter space failed.
Adapter request to update entity 60b62d76-d1cd-419a-8ed2-9fb864450855 to adapter space 116f12ec-6b0e-4071-a6e9-ef850e1ba7cc failed with reason 1 items failed schema validation during Adapter operation. Check log for validation errors.. Duration: 00:00:00.0039063
Error details:
Unify.Framework.UnifyConfigurationException: 1 items failed schema validation during Adapter operation. Check log for validation errors.
at Unify.Product.IdentityBroker.Adapter.GetValidEntities(IEnumerable`1 transformedEntities)
at Unify.Product.IdentityBroker.Adapter.UpdateEntities(IEnumerable`1 entities, Boolean reflect)
at Unify.Product.IdentityBroker.Adapter.UpdateEntity(IAdapterEntity entity, Boolean reflect)
at Unify.Product.IdentityBroker.Adapter.UpdateEntity(IAdapterEntity entity)
at Unify.Product.IdentityBroker.AdapterNotifierDecoratorBase`1.UpdateEntity(IAdapterEntity entityToSave)
at Unify.Product.IdentityBroker.LDIFAdapterBase.ExportChanges(ExportedLDIFForAdapter exportedLdifForAdapter)
at SyncInvokeExportChanges(Object , Object[] , Object[] )
at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage31(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)

Of note is that the key field in the log is "<null>" when it appears in the adapter entity search.

Affected Versions:
Fixed by Version:

This was due to the fact that ExportChanges had changed for the LDIFEngine work, and was clearing the entity prior to adding changes to it. I have made the relevant changes and will confirm with the next build.

Confirmed and closed in test 2