Node type definition in the CRX package
To meet the requirements I have implemented a custom nodetype that is placed inside the bundle within a package. The nodetype is used at the same time by a content that is also available in the same package.
The problem is, while installing the package for the very first time on the instance, the nodetype definition is missing in the registry as it hasn't been grabbed yet by JcrInstaller that takes care of bundles. Each subsequent installation is just fine as the nodetype definition is not being uninstalled by default.
What is the option to get out of this situation without splitting package into two i.e. bundle with nodetype definition and the rest?