You may be describing a condition called jumper's knee. This is an inflammation of the patellar tendon just below the kneecap. The most common activity that causes jumper's knee is repeated jumping or running.
Greater weight and height are factors that can make this condition worse with overuse. The force generated through the knee puts an increased load on the tendon. Sports like volleyball and basketball have the highest rate of jumper's knee.
This type of inflammation and discomfort can last weeks to months. Recover may depend on the severity of the condition. Treatment is important to keep the inflammation from getting worse and causing long-term damage. It's best not to overuse or over train during treatment.
A sports doctor, physical therapist, or athletic trainer can help you determine the cause of your symptom(s) and set up an appropriate treatment program.