If you really want to get technical about the term Mary Sue, it originates from Star Trek fanfic. It would feature the author inserting an idolized version of themselves into a story. Often as ensign who would team up with or aide the heroes (Kirk and crew) to save the day. Quickly rising the ranks, get the guy/girl, etc, etc. Then leave. The Mary Sue was never a permenant member of the fictional universes they were inserted in. They were not the heroes.
That's why Luke isn't a Mary/Gary Sue. He's the hero of Star Wars.
That's also why Rey isn't a Mary Sue either. She's the hero of TFA and the new trilogy.
Didn't it originate from a Star Trek fanfic character actually named Mary Sue?
In any case, it's silly to argue about the believablity of magical characters outside the context of their magical worlds. I think that the only legit beef that people can have with regard to the Rey character is the flying of the MF. There is nothing in the background of the character that would suggest that she would be able to fly the Falcon. I mean, sure, piloting is a talent that apparently runs in the Skywalker line, but unlike Anakin, who had been flying pods already, and Luke, who was pretty nervous flying the X-Wing on the Death Star run, Rey seems completely at home and not at all nervous doing complicated maneuvers in an old hunk of junk, which seems a bit implausible. Even more implausible is that she had no hesitation about flying it out of the atmosphere, when she apparently had not been off Jakku since she was four or whatever.