Spontaneous emission in confined space