Closed ktmcgrat closed 6 years ago
Hi @ktmcgrat , thanks for reporting. As you mentioned, this is MuleSoft's Anypoint Platform. There is nothing we can do with the Designer itself. May you please contact someone from the MuleSoft support team and rise a ticket for this? Let me know. Hope this helps Regards
Hi @ktmcgrat! I am closing this as is not reproducible anymore in API Manager.
Moving modified files within API designer and deleting their original directories can lead to SQL faults being thrown.
This occurs on the current API Designer at anypoint.mulesoft.com. I was using Chrome on Mac.
Steps to reproduce:
Click :Define API in API designer" for a brad new API from API manager. api.raml already exists. Create a directory named test by clicking "project, new Folder", and entering name. Now click Project, new File, RAML 1.0, API Spec. Go with default name api-1.raml.
api-1.raml will open, click Project, Save All. Now drag api-1.raml into the test folder. now edit api-1.raml by adding anything to this file, so that it shows as modified but not saved.(such as setting the value for title) Now drag api-1.raml out of the test folder and back into the top level. Right click on the test folder, and select delete and confirm deletion. At this point you have two files showing, api.raml and a modified but unsaved api-1.raml. Select project->Save all
You get this error update "ApiVersionFiles" set "apiVersionId" = $1, "id" = $2, "isDirectory" = $3, "masterOrganizationId" = $4, "name" = $5, "organizationId" = $6, "parentId" = $7, "remoteSystemId" = $8 where "masterOrganizationId" = $9 and "organizationId" = $10 and "id" = $11 returning "updatedDate" - insert or update on table "ApiVersionFiles" violates foreign key constraint "ApiVersionFiles_parent_fkey": Key (masterOrganizationId, organizationId, parentId)=(5b43ee3b-0623-45ac-a5e1-6a85db9c8e9b, 5b43ee3b-0623-45ac-a5e1-6a85db9c8e9b, 1361019) is not present in table "ApiVersionFiles".