Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HWKAPM-478 Support caching information in a clustered environment #444

Merged
merged 1 commit into from Jun 19, 2016

Conversation

objectiser
Copy link
Contributor

No description provided.

@objectiser
Copy link
Contributor Author

objectiser commented Jun 16, 2016

Review notes - this PR contains some minor changes relates to serialization of some events to deal with null strings. The main change is how cached data (Producer Information and Communication Details) is stored. The initial implementation assumed when clustering the servers a distributed cache would be used - however due to problems getting the distributed cache working lead me to rethink this approach - as the data being cached is distributed via JMS anyway, rather than redistribute it again via infinispan, it seemed better to leverage local caches (to help with memory management) that are initialised via the JMS published data.

There are some potential issues, discussed in https://issues.jboss.org/browse/HWKAPM-479, which may mean a distributed cache will eventually be used, but while the main focus is on monitoring short lived transaction/trace instances, this seems like a viable solution. So the main changes are to introduce some non-durable subscribing topic MDBs to receive the data and store it in the local caches.

/**
* @author gbrown
*/
public class SerializationUtil {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have you looked into using some other serialization library instead? I recall that the default from the jdk is rather slow and clumsy.
I don't mean that you need to change it now

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No haven't looked into any others yet, but if can look at others if the performance in this area becomes an issue. Currently the serialization is only used with the caching.

@pilhuhn
Copy link
Member

pilhuhn commented Jun 17, 2016

I think it certainly makes sense to pick the data from the Topic, if it is sent there anyway, to update all local caches.

@jshaughn
Copy link

The initial implementation assumed when clustering the servers a distributed cache would be used - however due to problems getting the distributed cache working lead me to rethink this approach...

This is also disturbing as we're depending on ispan caches in a couple of other places. Can you elaborate?

@objectiser
Copy link
Contributor Author

I had two wildfly 10 servers running in a cluster, with a distributed cache defined in the standalone-ha.xml. Logs showed the cluster was being established, but for some reason no data was being shared between the nodes.

Its most likely I got some config wrong, but once I thought about the current solution (based on JMS), I didn't investigate further.

@objectiser
Copy link
Contributor Author

@pilhuhn Added the extra test, and changed MDBs so now use durable topic subscription based on a clientId associated with the 'jboss.node.name'.

@objectiser objectiser force-pushed the HWKAPM-478 branch 2 times, most recently from d974c25 to 4739562 Compare June 17, 2016 16:23
@objectiser
Copy link
Contributor Author

@pilhuhn ok to merge?

@pilhuhn pilhuhn merged commit 89a96dd into hawkular:master Jun 19, 2016
@objectiser objectiser deleted the HWKAPM-478 branch June 20, 2016 07:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants