While deploying a model to our CUS layer on a client’s test environment (2012 RTM), the documented process I have is as follows:
stop the AOS
import the model
start single AOS
compile the App (this is done by right clicking on the root of the AOT and selecting Compile)
full CIL generation
sync DB
Steps 1-4 are fine, but when I perform the full CIL generation nothing happens, I don’t even get an infolog. I can perform an incremental CIL instead and I can sync the DB and everything seems ok with the application but I am trying to understand if we have an issue here.
“9. Compile the application. This step includes CIL compilation”
Does this mean that I should compile the CIL manually at this stage in the process or that if I perform a code compilation (step 4) then a full CIL is generated automatically?
No, X++ compilation doesn’t cover CIL. It just mean that you should compile all code, both X++ and CIL.
If CIL compilation does nothing, something is wrong in your system (e.g. there may be an unhandled exception). You can debug the code in SysCompileIL.generateIL() to see where it stops.
I entered a breakpoint in that method, retried it and the debugger fired. I removed the breakpoint and just let the code run and it has gone through 3 passes successfully and generated a full cil. not sure if this was the breakpoint (unlikely) as a few days have passed since the model was last installed on this environment.
I will keep an eye on it next time I do a deployment and debug it immediately, if necessary. I I discover the specific root cause I will share it.
By default AX will create a log file under \bin\xppIL directory which will contain details of CIL compilation. If CIL generation failed for whatever reason, this file should provide some clue.