[Installation, Configuration & DEPLOYMENT] - Re: NoClassDefFoundError and ClassNotFoundException errors d
by naguilar
Issue Resolved. The reason why I was getting this error was not not because isolation was turned on, it was because the servlets in my WAR file were loading on startup and they referenced classes that existed in the EAR file. Since the WAR and EAR were deployed seperately, the WAR was being loaded before the EAR file and therefore the classes were not found.
The solution was to fix the deployment order so that the EAR file was loaded before the WAR file and this was done by updating the \conf\xmdesc\org.jboss.deployment.MainDeployer-xmbean.xml file.
The following is the line I changed:
<value value="250:.rar,300:-ds.xml,400:.jar,500:.ear,550:.jse,650:.war,800:.bsh"/>
As you can see, ear now comes before war.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4171762#4171762
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4171762
17 years, 8 months
[Remoting] - How to insert new server-side application protocol based on
by balibalo
Hello,
I hope being on the right forum.
I am trying to port a custom protocol into JBoss, server side. It is a trivial synchronous protocole made of string data and binary data (in fact, compressed stuff). I can't tell much about it but it really looks as dummy as:
client -- connects via SSL (2 way handshake) --> server
client -- hello --> server
client <-- hello -- server
client -- how are you? --> server
client <-- fine -- server
client -- ok --> server
connection is closed
I have read much about Invoker and Remoting but it deals with RMI, however I don't need RMI (the client part is coded in C etc...). Am I on the wrong way?
My idea is to create a service that listens to a configurable port, whenever a connection arrives, it enables the SSL and it creates a thread that will handle the custom protocol.
I am aware that JBoss is able to do most of that already, but I don't know how to use it for my purpose. Which element to use, configure, which class (in addition of the class that handle the protocol) do I need to code and where.
Any idea/tips or existing documentation?
Thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4171760#4171760
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4171760
17 years, 8 months
[Beginners Corner] - How to reliably count active sessions (re-post)
by mrgordonz
Hi JBoss gurus,
This is a slightly re-worded re-post (http://www.jboss.com/index.html?module=bb&op=viewtopic&t=140995) because I wasn't getting any replies.
I would like to reliably monitor the number of active sessions for a particular web application deployed on JBoss 4.0.5 (the server is Windows Server 2003; JDK is Sun 1.4.2_14). I didn't create the app - I simply provide hosting for a growing number of customers.
Initially I looked around for monitoring tools (eg: Hyperic) which would do all this for me, but alas they all seemed to monitor everything EXCEPT active sessions for a particular web app. But I did find one (AdventNet Application Manager) which does the next best thing (for my purposes) - it will execute a script and monitor the output of the script.
For example, say I have a script called sessions.bat, and when it is executed it will (somehow) output the number of sessions to a log file, sessions.log . Sample log file contents might be:
active_sessions=65
AdventNet Application Manager will execute the script at a desired interval (say every 15 minutes), and then read the contents of the resulting log file. I can even specify that it needs to look for the string "active_sessions", and monitor the corresponding numeric value (it even creates pretty graphs for me!).
BUT - I need a script which will output the number of active sessions.
I have done a bunch of searching, and posted on other forums, and so far most people have suggested that I need to write my own class which implements HttpSessionListener, and in the class I keep a running tally of sessions as they are created and destroyed.
However, one person suggested I have a look at the "JBoss Management Console" (http://my-server:8180/web-console/),
anonymous wrote : ...then in the console function tree find: Monitoring - > Web Status -> Full Status.
| You will get a page with loads of stats on the right side.
| Find [Application list] and link to your application, simply click on it and at the top of the page you will see all the stats that you need...
I had a look at this and it has exactly the information I want - Active sessions , Session count , Max active sessions, Rejected session creations, Expired sessions , Longest session alive time , Average session alive time. But, how can I get that info into a log file (of my choosing)? According to the person who pointed me in the direction of the JBoss Management Console, this data is not stored anywhere (eg: a log file).
So the big question for me is how does JBoss get this information? Are there built-in APIs which are called by the Management Console? If so, is there some way I can call those APIs using a batch script or a custom class?
My ideal solution would be to have a very simple batch script which simply executes/calls a class (which will probably be one I have to write myself, or get help to write). That class then gets the info which is available in the Management Console, and pumps it into a log file in the following format:
active_sessions=35
| session_count=672
| max_active_sessions=82
| rejected_session_creations=0
| expired_sessions=637
| longest_session_alive_time=6618
| average_session_alive_time=1944
I have no idea if this is possible, but I am hoping like mad that it is. Please, please, someone tell me it is possible to get this information! Better yet, tell me not only it's possible, but how! :)
Cheers,
Paul Hobbs
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4171759#4171759
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4171759
17 years, 8 months
[Installation, Configuration & DEPLOYMENT] - Re: Can't remote to Jboss, -b 0.0.0.0 not working
by Bombarta
The tool is irrelevent, but it's called "Java Service Wrapper". Rather than running JBoss from a CMD window, it runs it as a windows or linux service depending on your platform. It's irrelevent simply because I've tried -b 0.0.0.0 from the cmd prompt as well as trying to include it in the executable line of run.bat .
run.bat -b 0.0.0.0
Now this is JBoss 4.2.3, and from my understanding, as of 4.2 the security tightened up and now locks JBoss to localhost only. Well, this does me no good. I've read that using SSH/putty you can tunnel a port remotely, however the -b 0.0.0.0 seemed simple enough. My concerns for security are minimal. The server and PC's that need to remote are on a closed network, so I'm not concerned with outside sources attempting to use the admin console, etc.
So what other info can I provide to help with my problem? I'm pretty new to JBoss, however I've been running Glassfish for some time now and do have a little knowledge about J2EE app servers.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4171755#4171755
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4171755
17 years, 8 months