The invention provides compounds of Formula I: wherein A, L, m, q, Q, R1, R2, R3, R4 and R5 are defined in the Summary of the Invention. The invention further provides for pharmaceutical compositions comprising such compounds and methods of using such compounds to treat or prevent diseases or disorders associated with the activity of GPR119.