Calculate $\int_0^{2\pi} \frac{1}{2+\sin(x)} \ dx$ $$\int_0^{2\pi} \frac{1}{2+\sin(x)} \ dx$$
$$\sin(x)=\frac{e^{ix}-e^{-ix}}{2i}$$
$$z=\alpha(x)=e^{ix}$$

$$\sin(x)=\frac{z^2-1}{2zi}$$
$$2+\sin(x)=\frac{4zi+z^2-1}{2zi}$$
$$\frac{1}{2+\sin(x)}=\frac{2zi}{4zi+z^2-1}$$

$$\int_\alpha \frac{2zi}{4zi+z^2-1} \ \ \frac{1}{zi}$$

$$4zi+z^2-1=0$$
$$z_1=\frac{-4i+2\sqrt{3}i}{2}$$
$$z_2=\frac{-4i-2\sqrt{3}i}{2}$$

$$\rvert z_1 \rvert <1$$
$$\rvert z_2 \rvert >1$$

Using Residue theorem:

$$\int_\alpha \frac{2}{4zi+z^2-1}=2 \pi i \ \lim_{z\rightarrow-2i+\sqrt{3}i} \ \frac{2}{z+2i+\sqrt{3}i}=\frac{2 \pi}{\sqrt{3}}$$

Is it correct?
Thanks!

Another way is 
Set $u=tg\frac{x}{2}$ and $du=sec^2\frac{x}{2}*\frac{1}{2}dx \rightarrow dx=\frac{2}{1+u^2}dt$ and $sin(x)=\frac{2u}{u^2+1}$
$$\int_0^{2\pi} \frac{1}{2+\sin(x)} \ dx=\int_{-\pi}^{\pi} \frac{1}{2+\sin(x)} \ dx= \int_{-\infty}^{\infty} \frac{2}{(u^2+1)(\frac{2u}{u^2+1}+2)}=\int_{-\infty}^{\infty}  \frac{1}{u^2+u+1}$$ 
And to solve this just complete the square and you will get something in  function of $arctg(u)$
