All the content added in the CMS is being added to the document type yaml files.
I have integrated the CMS with MySql but my yaml files are storing all the new content being added in the CMS which is causing the yaml files to grow in size, taking up huge space and also causing delay in application build and restart.
Is it something related to bootstrapping the project. If so can anyone please guide me what to do?
By default, the auto-export feature is enabled for the convenience of developers who want to bootstrap content data in YAML before deployment.
Follow the “Disabling Automatic Export from the Console” section  to disable it by default.
If your repository.xml is pointing to a dataSource backed by the MySQL DB, then any changes through CMS app will be persisted in the MySQL DB.
Actually “auto-export” is an indepedent concept from the repository DB. In local dev env, normally with an H2 DB setup, when running cargo.run profile, it also saves any changes locally to your H2 DB. But the reason why it looks like transient is usually it cleans up the local H2 file db with mvn clean ....
“Auto-export” feature is usually “on” in local dev mode with mvn -Pcargo.run because the feature needs to finds your project source locations to bootstrap yaml files to local files. Otherwise, it won’t serialize files.