It’s mostly personal preference for having the light flush with the barrel or not. The deciding factors usually aren’t the length of the light itself, but rather finding a holster for that gun/light combo and choosing the amount of lumens you want. The P10 with a light doesn’t have a ton of options from holster makers so that already limits you some.
There is some benefit to having it flush i.e more compact, easier to draw from holster and reholster. The cons would be that the lens of the light gets dirty from expelled gases and you don’t have the ability to use the light as a standoff device for up close contact shooting.
I’ve included a few articles that I reference when talking about lights and that helped me choose the light I eventually will add to my Glock19. Personally, the Surefire X300 and the Streamlight TLR-1 are the top two in my book.