Could be a couple of things going on here. First, rotting fruit just before ripening is typically brown rot. Get an appropriate fungicide from a garden center and follow instructions.
The gel is just sap, and it oozes in response to injury, diseases and pests. Sometimes, it's not a cause for concern. But if you are seeing a lot of it on the trunk, you may have a bacterial disease, or maybe peachtree borers (or possibly something else but those are most common). The injury can look similar superficially with all the oozing sap. But if you have borers, you'll notice small holes in the trunk, and probably fine sawdust, which the borers expel from their holes. You often see both, because borer damage creates an entry point for diseases.
These are common problems, and there are several good sprays for borers you'll find at garden centers, but if you determine that's the problem, don't dally. They can destroy trees quickly. There isn't a good solution to bacterial canker once it gets going, unfortunately.