Ignite native persistence replaces Swapping feature from Ignite 1.x. Use native persistence instead of swapping (remove "swapPath" configuration and enable persistence).
"swapPath" setting in Ignite 2.x has different semantics: specifying a "swapPath" makes Ignite use memory mapped file for the data region instead of off-heap RAM. This is why you see all data go to the file.