I had an invasive abdominal hysterectomy and my ovaries removed several years ago, so I can certainly understand your concern and offer some advice.
Before your surgery, practice abdominal breathing. Spend time focusing on the rise and fall of your belly as you breathe—a very calming practice which will relieve tension in your pelvis and be helpful as you recover. If you like backbends, do them as much as possible before your operation because it will be some time after the surgery before you can do them again.
As soon as possible after you wake up from your surgery, start with simple movements like turning your head from side to side and moving your hands and feet to help your body re-energize. With your knees bent and feet on your bed, your can rock your legs lightly to each side. You can also place a pillow under your hips, so that you are in a soothing, supported pelvic tilt.
See also Work Your Core in Any Pose
After you leave the hospital, sit in Virasana (Hero Pose)—even hunched over—to start to stretch your front thighs. Gradually move into supported Supta Virasana (Reclining Hero Pose), (reclining on a bolster), being careful not to arch your back. My supported pelvic tilt gradually evolved into supported Viparita Karani (Legs-up-the-Wall Pose), which you can do to open your upper body. Forward bends might ease tension in your back, and a standing pose like Virabhadrasana I (Warrior I Pose)—done with a very short stance to avoid stretching the abdomen—will actively stretch your legs.
When the incision is completely healed, you can re-introduce poses that start to stretch the front of your body. I started with Marjaryasana (Cat Pose) and gradually worked my way into Bhujangasana (Cobra Pose), which I still find the best pose for stretching out the scar tissue. Twists can also help to stretch adhesions, especially Ardha Matsyendrasana (Half Lord of the Fishes Pose).
If you are having your ovaries removed as well, you will also be dealing with the effects of menopause, which can affect both your energy and flexibility. You may find that you tire easily for quite a long time after your surgery and may need to do a lot of restorative practice. Rest assured that with time and patience, you can rebuild your yoga practice to its present level and beyond.
The late Esther Myers’ 10 years as a student of Vanda Scaravelli inspired her to find her own unique, organic approach to yoga. Esther taught classes across Canada, Europe, and the United States before her death from cancer in 2004. She left behind a practice manual for beginners and a book titled Yoga and You, as well as two videos, Vanda Scaravelli on Yoga and Gentle Yoga for Breast Cancer Survivors.