You can solve this by separating the foreground and background elements and rendering them separately, then using the compositor to re-combine them.
Result of this approach
First, render only the very background - the object(s) that is behind everything else, and save to file:
Then, make sure you set the background to transparent.
Then render the static foreground elements (the elements above everything else that aren't animated) and save to file:
Now you can render your dynamic, animated element separately from the rest. Make sure you render to an image sequence of PNGs with transparent background:
Now all you need to do is open the compositor and use alpha over nodes to composite the static and dynamic elements, then render it all out together to one video file (or a new image sequence):
Alternative node setup using Z combine:
You can find the blend file that was used for this answer here. Good luck!