Gibbs sampling for mixture with Dirichlet prior?

I want to sample from the distribution of a mixture distribution. The hierarchical model is $$x_i\sim f$$, where:

$$f(x\mid \theta_1,\dots,\theta_p, w_1,\dots,\omega_p) = \sum_{j=1}w_p\varphi(x\mid\theta_p),$$ and $$\theta\sim\pi(\theta)$$ for some appropriate prior and $$w\sim Dirichlet(w\mid \alpha)$$.

Is it possible to sample from such distribution using a Metropolis within Gibbs sampler? Is there some reference I can read to implement such sampler. My main concern is to properly account for the fact that $$\sum_{j=1}^p w_j = 1$$.

• Metropolis gives complete freedom in the choice of the proposal so what is exctly your question? – Xi'an Aug 12 '19 at 11:10