There are two mysteries to be solved in 'The Wild Rover' on Castle tonight. One: Why is Castle (Nathan Fillion) muttering the name "Jordan" in his sleep? And two: How is the Irish mob connected to the death of a local cupcake shop owner found shot and dumped in his own industrial mixer?

The Jordan mystery is solely in Beckett's (Stana Katic) passive agressive court, but it takes her the entire episode and a few threats to get the answer out of him, so let's focus first on the murder instead. For this part of the story, all eyes are fixed on Kevin Ryan (Seamus Deaver), who rarely is given much to do beyond your typical team player stuff (not to mention a few good punch lines). However, Deaver is up to the challenge.

The first challenge comes in the form of a woman named Siobhan O'Doul (Cara Bouno), who, upon seeing Ryan in the police station, proceeds to greet him with a kiss followed by a hard slap across the face. All this while his wife Jenny - played by Dever's real wife, Juliana Dever - is looking on in utter confusion.

Castle season 5 episode 18 Ryan Siobhan Jenny

The rest of the team is at a loss, too, and after settling things with the missus, Ryan confesses that he spent a few years as an undercover cop before switching over to homicide.

That stint gave him inside access to the same branch of the Irish mob Beckett suspects is behind the murder. Because Ryan had been close to mob boss Bobby S (Michael Rodrick) and because Siobhan could be killed if Bobby suspects she's become an informant, Ryan agrees to reintegrate himself into the group as Fenton O'Connel, his former cover. Ryan is also determined to get his hands on the mob's "bible," or logbook, which could contain enough evidence to take Bobby S off the streets for good.

A haircut and a few wardrobe tweaks later and Ryan is on his way to Staten Island. Fortunately, the casting director for this episode decided to go for good guest stars as opposed to guys with bad Irish accents and Clairol-red hair. Of course, bars are still bars and mobsters are still mobsters, but they didn't go too over the top with the motif.

The scene between Ryan, Bobby S, and Bobby's right-hand man Liam (Brian Letscher) in Bobby's office is very well-done, topped only by Dever's stand-out scene at the end when he plays his final hand. Also, who knew Ryan was a pool hustler?

Castle season 5 episode 18 Ryan

The story is a good one in terms of the case, and leave it to Castle to draw the parallels between the murderously ambitious Maggie (Christina Cox) and Lady Macbeth. It also highlights what a good team this group has become over the years and how they've evolved. Good news for Ryan and Jenny fans, too, as the couple discovers all of their fertility worries were for naught: she's pregnant!

As for Castle's inappropriate murmurings of a certain "Jordan," the end result of that mystery adds a new depth to his character as well. A young Rick Castle on the verge of failing paid for a paper on the car company by that name. It was the first academic achievement he was praised for and he has spent the rest of his life escaping that guilt and proving to himself that he was more than a mere forgery - that he could be a real writer. Like Kate, this serves to engender him to the audience just a little bit more.

Castle airs Mondays @10pm on ABC. Make sure to tune in next week as Castle celebrates its 100th episode.