I have problems to understand mongos routing for sharded clusters. If i have a Server where i have ubuntu running and on the same machine a webserver and also a tomcat application server. Now both want to connect to a mongodb sharded cluster. Is the mongos instance running on the machine and it is possible to connect to it via php and java from both servers?
Yes, any number of client applications on a single host can connect to the sharded cluster through a single local mongos process.