Jen, I have a guy friend who has an anxious attachment style (Google attachment styles for further explanation). He keeps getting into relationships but gets anxious about keeping it. He self destructs. This comes from his family-of-origin (doesn’t most everything?). I believe he cannot be in an intimate, romantic relationship until he addresses it through therapy or some other means that addresses this underlying anxiety issue.
So for you feeling lonely even if you are with him, that you want him to fill a void, and that you have been in such a situation before all points to dealing with your issue. You are reaching out for strategies for letting go and not being so anxious. My take is that your issue is best addressed with a therapist rather using online advice. Good for you to recognize what is going on with yourself now and reaching out for help.
Mark