We put lately more attention to monitoring and tuning our systems – mainly db. I tried to refresh in mind how to check active sessions on jvm for specified app. I’ve experimented with VisualVM, but it didn’t satisfied me. I simply does not work out-of-the-box. After registering jmx remote host, I could not expand apps list…
I need something more standard and working then that. I’ve run “jconsole” (attached to each jdk copy).
Then I’ve connected to: myFavouriteAppsserver.com:8686
and under the path: com.sun.appserv/Manager/myAwesomeAppName/server/Attributes
I’ve found to variables: activeSessions and sessionCount. Take a look
A quick remark for the future that is worth to remember. I suppose there is one of good coding principles to keep your imported WSDL files up-to-date.
I was writing distributed ticket handling system. I needed some stateful service for this. I’ve implemented this storage with database behind and ejb-webservice as endpoint. While I was coding I’ve wrote module for creating, modifying and closing ticket in natural order. For every action I wrote separate module. During implementation (after having done first two modules) I’ve implemented a new method in ejb-webservice what changed it’s WSDL file which I’ve used in the third module (but having not updated first two). You could imagine that this is wrong. My app server (glassfish) [I suppose] creates one wsdl file in memory for one endpoint so there is no possible way to keep two different versions of it (one with additional method and one without). Of course before that deployment and compilation were fine. This issue turned out while testers went through test scenarios.
I wrote an composite application with webservice as entrance endpoint for client system. When I was previewing the wsdl file I’ve notice there is only host name without full domain name(as it is in DNS servers) give in schema location and webservice endpoint. That was obviously wrong, because client would not be able to resolve those adresses. I remember I had this issue one in the past. After a talk with my friend I’ve decided to search resolution with operation system Solaris 10 then with application server.
The resolution of this problem is easy and strange. Maybe because Glassfish is very sensitive?
- Let’s say my host is called tiger. My domain name is mycompany.com. In schema address I saw:
and it should be
something was missing.
- To fix this you should edit /etc/hosts and change order of strings
before I’ve got:
127.0.01 tiger tiger.mycompany.com
after I’ve got:
127.0.0.1 tiger.mycompany.com tiger
That fixed my problem. I hope it won’t break anything else. I suppose only glassfish is so strict about the names of hostname.
Hi, for your convenience I’ve put that sample code on git repo. You can download it, experiment with it, learn etc. I suppose it will be easier for you getting it from github then waiting for an email from me.
What is going on? Once I’ve watched
the guru said that making java chip is very expensive…and only Intel could afford it. And a few month later then I found Polish company GryfTechnologia producing and selling Java Hardware Virtual Machine. The chip’s name is my the name of my lovely city. Warszawa! Poles are cleaver. They are brighter than the rest of world. Good luck GryfTechnologia! That’s awesome what you are doing!