Now knowing that:
- Both parties do not have internet
- DDns is not an option
- Broadcasting not allowed
The only option left is, when the android fails to connect to the server, try talking with every found ip on LAN one-by-one until someone respond.
This should of course be done in a fashion so that only your server would respond correctly.
As you are on a LAN this loss in connection should happen very rarely, if ever, unless server is restartet. Though, that depends on the LAN setup.