In order to get the user details , you shouldn't not create any session or respository object for publish. That would result in impacting end users.
Firstly , this requirement is little strange. But to solve the problem, simplest way that i would think is to hit a querybuilder.json api to fetch user data from /home/users. This requires hardly http connection in your java code. No other objects.
Example URL -
http://localhost:4900/bin/querybuilder.json?type=rep:User&nodename=*username