Connect to db from web app with one user then set role to real user: <a href="http:&#x2F;&#x2F;stackoverflow.com&#x2F;questions&#x2F;2998597&#x2F;switch-role-after-connecting-to-database" rel="nofollow">http:&#x2F;&#x2F;stackoverflow.com&#x2F;questions&#x2F;2998597&#x2F;switch-role-after...</a><p>This allows pooling.<p>I made a quick app with pg 9.5 rc1, rls, spring data rest which I&#x27;m hoping to share next week.