I usually hate flashback episodes. I always feel like they are a cheap trick by the show runners to save the cost of filming new scenes. Usually, a flashback episode does little for the viewer except perhaps for those who want to see their favorite scenes replayed. (Well, you can get a lot of those from one of the most popular websites featuring video clips.)
This flashback episode adds value. We just had two episodes establishing and lamenting that Castle had been taking Beckett for granted. This episode builds, piece by piece, the proof of Castle's love for Beckett, and perhaps to a slightly lesser extent, her for him. It culminates in the kissing scene which is pure passion. This episode is almost entirely about Castle and Beckett
We've seen little clues of a chink in their mutual love armor. And in episodes soon to come, the showrunners will expand on that chink so that when it comes to a crux in the final season the viewer, and more importantly Castle and Beckett, can understand it. Don't get me wrong. Castle and Beckett love each other. They really do. They don't understand yet what their chink is. It needs to be dealt with. And perhaps they still need to grow a little in that love so when the time comes they can make the right choices. There is some true brilliance in developing this thread despite what most fans concede is a general decline in the show especially in the last season. I don't know how early in the game the show runners started consciously developing this thread. I suspect there was some serendipity in this regard. But I have no doubt that Castle and Beckett are a true love story.
I've purposely not stated anything about what that chink is. I explain it, briefly, in my review of S8E15. So spoiler alert.