Recently I was able to get a JBoss cluster working fine with the default settings, but have a need for more sophisticated clustering/availability logic.
Specifically, I would like to have custom healthchecks that would return a different availability pool to the client, depending on a client parameter. For instance, I have a server cluster that maintains connection pools to three external entities. At any given time, an individual node may have lost connections to one of those three entities. So, from my perspective, I'd like to make this node appear available for client requests targeting the two entities with active connections, but unavailable for the entity with no connections.
Based on which external entity a client request is ultimately destined for, I'd like to present the client with the appropriate list of currently "healthy" nodes.
I have read (and reread) the clustering doc, but am not quite seeing whether this is easily possible. Suggestions or thoughts?