The old joke goes about the new rabbi who starts out in his new pulpit
The First week the Rabbi speaks about Shabbat. The Congregation pushes back - please don't preach about Shabbat, it makes the unobservant feel uncomfortable etc.
The second he week he speaks about Kashrut. Again The Congregation pushes back, please don't preach about Kashrut, it makes the unobservant feel uncomfortable etc.
The rabbi asks then what SHOULD I talk about?"
They answered: "Judaism!"
We know that you need not be Jewish to love Rye Bread nor to be a "good person"
So what makes us distinct?
Shabbat and Kashrut, to name a few, pillars of our Observance
Similarly what KEEPS us from assimilating into the Alien Culture?
Furthermore, why in P. R'eih in R'vii the Torah discusses Kashrut and in Sh'vii it discusses the Haggim?
I would suggest that the two bulwarks against assimilation in our society are Kashrut and Yamim Tovim. Few practices keep us apart from einam Y'hudim than our dietary laws and Observance of Our Calendar. In a 5-day work week setting, Shabbat is not quite such a distinguishing marker with regard to "taking off of work". But when one needs to Observe the various Haggim, THAT immediately sets us apart. And so it is with dining and socializing. We simply do not dine or drink together.
Note that the connection between Haggim and Kashrut occurs elsewhere in the Torah,too; EG in P. Mishpatim and Ki Tissa.
Summary: Kashrut and Yamim Tovim are how we differentiate ourselves as a Torah People. The Torah connects them because especially in Chutz La'aretz these are the markers that makes us distinct from all other peoples.