Thoracentesis is a minimally invasive procedure that doctors use to diagnose and treat pleural effusions. This is a condition in which there is excess fluid in the pleural space, also called the pleural cavity. This space exists between the outside of the lungs and the inside of the chest wall.