Hi everyone,
When I do a build or a full build I get a lot of errors. I think I know what's the problem but I don't know how to solve it.
At the beginnign (when all works) I had a project in FleetManager model. I made a table (VSSAutomataDocuments) and a dataEntity. Every thing was OK.
Then I realized the model wasn't the correct so I deleted de project and made another with mi correct model (CONModel). Now it's when the problems started.
I made a full build but i got errors. On event viewer i saw the next error:
- Duplicate metadata element has been detected in multiple modules. Please verify that application is deployed correctly and installed modules are compatible. Following elements are defined in more than one module: Element AxDataEntityView/VSSAutomataDataEntity is defined in the following modules: CONModel, FleetManagement
I went to PackagesLocalDirectory folder, searched FleetManagement model and deleted the element (VSSAutomataDataEntity).
FULL BUILD--> ERRORS
The same, "elements are defined in more than one module"
I deleted on Visual Studio all the objects (tables, dataEntites... about VSSAutomataDocuments), including the project. I went to models folders, searched the elements and deleted it.
FULL BUILD--> ERRORS
I searched on web and I found a community.dynamics question similar to my problem:
I did the build of FeetManagement model only --> Error
I did the build of CONModel model only --> Error
I don't know what more can I do. It seems like something isn't updating. Since I delete the first project I couldn't do a full build so -if I'm correct- for the system the element still existing.
Of course, because of this the client doesn't work.
In event viewer i have the next errors-->
- Metadata service communication retry attempts failed to resolve issues with the following settings AX7CertificateUserName: FRServiceUser@dynamics.com; AX7CertificateThumbprint: 1E3C9A2051440DAF5CBA11807B8D71E20705C876; AX7FederationRealm: spn:00000015-0000-0000-c000-000000000000; AX7ProviderName: mintedtoken.dynamics.com; AX7TokenIssuer: fakeacs.accesscontrol.windows.net/
Component: Microsoft.Dynamics.Integration.Common.TraceLog
User: NT AUTHORITY\NETWORK SERVICE
Machine: conDev2-1 - Failed to create a metadata service client in 5 attempts.
Machine: conDev2-1 - {"Class":14,"Number":2601,"State":1,"Message":"Cannot insert duplicate key row in object 'dbo.FINANCIALREPORTS' with unique index 'I_11477FOLDERREPORTNAME'. The duplicate key value is (5637144576, CON, Default Report Definitions, 12 Month Rolling Single Column Income Statement - Default).\u000d\u000aThe statement has been terminated.","ErrorCode":-2146232060,"Procedure":"","LineNumber":1,"Errors":[{"Class":14,"Number":2601,"State":1,"Message":"Cannot insert duplicate key row in object 'dbo.FINANCIALREPORTS' with unique index 'I_11477FOLDERREPORTNAME'. The duplicate key value is (5637144576, CON, Default Report Definitions, 12 Month Rolling Single Column Income Statement - Default).","Procedure":"","LineNumber":1,"Source":".Net SqlClient Data Provider"},{"Class":0,"Number":3621,"State":0,"Message":"The statement has been terminated.","Procedure":"","LineNumber":1,"Source":".Net SqlClient Data Provider"}],"ConnectionId":"2fa6c68a-68d7-42fd-a2e0-6d625b1249d8","Source":".Net SqlClient Data Provider"}
Machine: conDev2-1 -
AX is shutting down due to an error.
Duplicate metadata element has been detected in multiple modules. Please verify that application is deployed correctly and installed modules are compatible. Following elements are defined in more than one module:
Element AxTable/VSSAutomataDocuments is defined in the following modules: CONModel, FleetManagementException details:
Microsoft.Dynamics.AX.Metadata.Storage.MetadataReadCrossAssemblyDuplicateException: Runtime metadata is invalid because the same metadata artifact has been defined in multiple assemblies. \nFirst 10 conflicting names: VSSAutomataDocuments. \nSee metadata events for complete list.
at Microsoft.Dynamics.AX.Metadata.Storage.ErrorReportingHelper.ThrowMetadataReadCrossAssemblyDuplicateException[T](IList`1 artifactNames, IDictionary`2 modulesToArchives)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeProvider`1.GetPrimaryKeysNoCache()
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeProvider`1..ctor(RuntimeProviderConfiguration configuration, RuntimeModelManifestProvider modelManifestProvider, IDictionary`2 archives)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeExtensionProvider`2..ctor(RuntimeProviderConfiguration config, RuntimeModelManifestProvider modelManifestProvider, ExtensionLoader`1 loader, IDictionary`2 archives)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.RuntimeMetadataProvider..ctor(RuntimeProviderConfiguration configuration, Boolean extensions, ExtensionLoader`1 formExtensionLoader, ExtensionLoader`1 tableExtensionLoader, ExtensionLoader`1 enumExtensionLoader, ExtensionLoader`1 menuExtensionLoader, ExtensionLoader`1 securityRoleExtensionLoader, ExtensionLoader`1 securityDutyExtensionLoader, ExtensionLoader`1 dataEntityViewExtensionLoader, ExtensionLoader`1 edtExtensionLoader, ExtensionLoader`1 viewExtensionLoader, ExtensionLoader`1 querySimpleExtensionLoader, ExtensionLoader`1 menuItemDisplayExtensionLoader, ExtensionLoader`1 menuItemActionExtensionLoader, ExtensionLoader`1 menuItemOutputExtensionLoader)
at Microsoft.Dynamics.AX.Metadata.Storage.MetadataProviderFactory.CreateRuntimeProviderWithExtensions(RuntimeProviderConfiguration configuration, TableExtensionLoader tableExtensionLoader, MenuExtensionLoader menuExtensionLoader, FormExtensionLoader formExtensionLoader, EnumExtensionLoader enumExtensionLoader, SecurityRoleExtensionLoader securityRoleExtensionLoader, SecurityDutyExtensionLoader securityDutyExtensionLoader, DataEntityViewExtensionLoader dataEntityViewExtensionLoader, EdtExtensionLoader edtExtensionLoader, ViewExtensionLoader viewExtensionLoader, QuerySimpleExtensionLoader querySimpleExtensionLoader, MenuItemDisplayExtensionLoader menuItemDisplayExtensionLoader, MenuItemActionExtensionLoader menuItemActionExtensionLoader, MenuItemOutputExtensionLoader menuItemOutputExtensionLoader)
at Microsoft.Dynamics.AX.Metadata.Kernel.Accessor.Initialize(String binPath, String businessSqlConnectionString, IMetadataFlushContext flushContext)
at MetadataBridge.CMetadataProviderFactory.Initialize(Char* metadataPath, Char* binDirectory, Char* businessSqlConnectionString)
at InitializeMetadata(SqlLogin* )
at Microsoft.Dynamics.AX.AOS.StartupInternal(String[] Arguments)
As extra information:
- I can't start Microsoft Dynamics 365 Unified Operations: Batch Management Service (but I think it is due to the errors of the build)
- Before I delete the firs project the build worked fine.
- In IIS manager I realized the application pool "AOSService" is stopping continuously (I don't know if this is important)
If anyone know what to do now I will be very gratefull.
Thanks.