Standard Game Loops for lwjgl?

In beginning my first lwjgl game project today i realized that up until now i had been using a standard while loop for all my game loops (most of my stuff was up until now has just been simple test code to learn the ropes of lwjgl). But after i programmed the loop it i got an error: “Function is not supported” and turns out after doing a bit of googling that OpenGL calls (from one GL context) can only run on one thread. And up until now all my game loops i’ve made/used run on a separate thread to the main one.

My question is, does anyone have any examples of game loops that work well with lwjgl?

Here’s the code if your interested: https://gist.github.com/anonymous/ab50c60a57eca465242e