There is no one right answer. Depends on situation.
Some people I was totally over in 2 weeks.
One person I will carry with me lifelong. That person I will go to my grave loving.
If you feel that not "moving on" is a problem, then you may need to figure out - why can't you? Was it pride that was hurt? Do you honestly feel that person was the one true love of your life? Have you tried dating others? Do you want to "get back at" the person? Do you have unrealistic expectations, for example, thinking you will fall in love at first sight with someone new and if you don't, give up on him/her?
I mean, I can't answer these questions, only you can.
Would it help you to know we've all been through it? I once met a young man (he was just shy of 27, I was at that time about 3 years older) whose first every gf dropped him and when I told him not that it's any consolation, but we've all been there, he replied that it was consolation, he honestly thought he was the only person who'd ever been dumped.