web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Custom data entity url works fine even after its container Model is deleted

(0) ShareShare
ReportReport
Posted on by 792

Hi all,

Well, I have a confusion regarding Model delete.

I have created a Model in Customization (Overlayering) mode on ApplicationSuite, and created few data entities, classes etc. Now I chose to delete the model.

Steps I followed to delete the model:-

  1. Stopped AOS service from IIS.
  2. Manually deleted the Model folder from C:\AosService\PackagesLocalDirectory\ApplicationSuite path,
  3. Deleted the Model Descriptor file from the Descriptor folder.
  4. Then restarted AOS service.

Just to confirm the model deletion, I searched in the Visual Studio, and I didn't find any of my codes inside the Application Explorer, which is expected because there is no model.

But surprisingly, when I curiously tried to hit my created data entities' url from browser (https://usnconebox..../data/mydataentitypubliccollectionname), it went on successfully and all the data entities' rows were fetched properly!!!

How come this is possible? Have I missed anything while deleting the model? As my custom model is not there, there should not be any custom data entities as well. 

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Martin Dráb Profile Picture
    237,970 Most Valuable Professional on at

    When you compile X++, it generates CIL code and stores it in binary files (.dll and .netmodule). That's what gets executed; the original source isn't used when the application runs. Therefore deleting the source makes no difference, as you still have the binaries until you rebuild them (which you didn't do). In this case, rebuild ApplicationSuite packages.

  • Sagnik Majumder Profile Picture
    792 on at

    Okay, I followed your suggestion and started Build & DB Sync on Application Suite. (VS -> Dynamics 365 -> Build models --> select ApplicationSuite and its referenced packages, also selected DB sync as option).

    After whole build & db sync completed, I explicitly started "Synchronize database". It completed successfully.

    Even after that when I called dataentity url from browser, the result was fetching.

    Then I went to C:\AOSService\PackagesLocalDirectory\ApplicationSuite\bin and found all the .netmodule, .mdb and .xpp files of my model are present there!! They were not deleted during the build!!!

    So I manually deleted them all.

    Only then I found that dataentity url from browser is returning 'not found'.

    So I wanna ask, is there any concept of clean build in D365FO, during which all the old dlls and binary files are deleted strictly? Because just Build model of ApplicationSuite didnt delete my old binaries.

  • Sagnik Majumder Profile Picture
    792 on at

    Hi Martin, As I mentioned, building the ApplicationSuite alongwith refernced models followed by DB sync didnt resolve my issue. I manually deleted all the .netmodule & other binary files in C:\AOSService\PackagesLocalDirectory\ApplicationSuite\bin location, followed by AOS restart. Only then it actually removed the entire traces of my model.

    So is there any clean build (or rebuild) concept in D365 FO?

  • Martin Dráb Profile Picture
    237,970 Most Valuable Professional on at

    I don't whether it's a bug or a limitation by design. You would have to talk to Microsoft. Also, if you're not the latest version, try if it's still the same there.

  • Sagnik Majumder Profile Picture
    792 on at

    I have tried it in PU5, will check it in PU8 once (I think that's latest).

  • Sagnik Majumder Profile Picture
    792 on at

    Thanks Martin, for your help.  I have one parallel thread running which is stuck for quite some time and I'm not getting any answer on it. Would request you if you have time to go through this.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans