Fairly major commit. This will break the current version of ihost, but this had to be done really to give Pete something to test the new ihost against. The main change here is removal of the TCP Heartbeat functionality from the filter. This meant the following features stopped working :- - Heartbeat testing - Configuration checking - Service checks The heartbeat testing, specifically the monitor, now looks at the presence of UDP packets instead. Before it just looked for the presence of a TCP heartbeat packet, so the change their is fairly negligible. Of course this means heartbeat testing now relies on the UDP working... but I don't see this as a problem. Configuration checking has been repositioned in to the filtermanager. This is a backwards compatible change - the filtermanager should still perform as it should for older hosts. But now there's an extra command to check the configuration is up-to-date, with a similar format to the old TCP protocol in the filter. (although we may optimise this soon) The service checks are broken. This isn't a major issue for us as they were pretty useless in the first place. The concept is good, but the checks are just far too primitive. I expect at some point I'll work on a seperate component that just monitors services, which will replace this function. Further changes in the server include removal of the key checking code, as this relied on a bolt on to the TCP heartbeat protocol to ship the key. This got more akward than originally planned, so I'm happy to drop the idea. In the long term we hope to replace this with a public key systems for signing and even encryption. Finally, general tidy up to remove other bits of code that check for TCP heartbeat packets when they don't need to any more.
Changed the server to use the external util package. Quite a minor change, but does affect a lot of files.
Added URL to GPL headers.
i-scream is now licensed under the GPL. I've added the GPL headers to every source file, and put a full copy of the license in the appropriate places. I think I've covered everything. This is going to be a mad commit ;)
Send key *before* we add it to the key manager. The thinking behind this is that if the connection to the host fails, for whatever reason, we won't put the new key in the keymanager. This seems safer. But, as these two operations can't be fully atomic, it's inevitable that at some point a packet will arrive with an older or newer key than that in the key manager.
Removed a few lines of unused code.
Initial work on host authentication for the server. Until I can get ihost doing it's side of the host authentication I can't really test any further. It seems to work, as in it filters data which isn't authenticated when told to do so in the config :)
Made the ACL's dynamic where appropriate. This isn't perfect, the ACL will only get reloaded after the next connection. This is because the check is done in the main while loop, and will only get done before a new thread is spawned to deal with a connection. It will have the desired effect though, I hope :)
Major change in the java package naming. This has been held off for some time now, but it really needed doing. The future packaging of all i-scream products will be; uk.org.iscream.<product>.<subpart>.* In the case of the central monitoring system server this will be; uk.org.iscream.cms.server.* The whole server has been changed to follow this structure, and tested to a smallish extent. Further changes in other parts of the CMS will follow.
The whole server package structure has been changed. Old Package: uk.ac.ukc.iscream.* New Package: uk.org.iscream.*
Opps, seems a protocol error managed to creep in.
Modified to use the ConfigurationProxy. Also took the opportunity to fix some of the issues with TCP communicates - specifically checking for nulls. This makes the configuration more dynamic, but do note that the TCP/UDP ports are only set on startup. This is because it would require lots of extra work to "change" the ports that the Filter is bound to on the fly.
Given all the classes that extend Thread a name using Thread.setName(). It is only representative as far as it will tell us which class the Thread is, but this will go some way to aiding debugging. If time permitted, more effort could be taken to name each thread according to what it was dealing with.
Seem to be getting a lot of ERROR logs from this class. Maybe this will help us identify exactly what is happening.
Send heartbeat packets with lowercase hostname.
Ah, that time should be in seconds really. Hopefully this will confuse something that wasn't conforming :-)
added a line of logging
initial checkin of the service check functionality
Made use of the autoflush feature of PrintWriter.
General tidy up, specifically focussing on the verbosity of logging messages.
Some tidying up.
Changes to reflect move of Component, ComponentStartException, and the ReferenceManager from util to componentmanager.
A structural change to the Filter. The old setup looked like this; UDPReader ------> FilterThread (thread) --> (parent) TCPReader ------> FilterThread (thread) --> (parent) FilterServant --> FilterThread (thread) --> (parent) Seeing this from a threaded point of view, each time a packet came in (through whatever means - UDP, TCP or CORBA), a FilterThread instance was created to deal with it. If the link to the parent was slow this resulting in a build-up of FilterThreads all waiting to talk to the parent - and there is only one actual parent object, with a synchronised thread, so they have to queue up anyway. As a result of this, the following change has been made. UDPReader -------\ TCPReader ----------> Queue (single) >-- FilterThread --> (parent) FilterServant ---/ In this setup, each of the three objects that generate packets only see the single instance of a Queue. They all add their data to this Queue, and then carry on with the task of listening. The FilterThread (having it's role changed slightly) now acts as a consumer of the Queue, in that it grabs data from the Queue and deals with passing it on to the parent. This setup should be more efficient in the long run, especially under a high load situation. The only problem could be the Queue growing to an unlimited size, but this is a Queue design issue.
componenterized the filter and tidied all child classes, no all conform to toString standard
Changed package structure uk.ac.ukc.iscream.refman and xml -> uk.ac.ukc.iscream.util
Changed all classes so that references to the Logger and ConfigurationManager are no longer passed around between classes. All of the classes now utilise the new ReferenceManager, which makes life much easier. Also tidied everything so that they all use the same conventions for attributes, namely the _ prefix to the name.
Update for package move. Fixed bug in constructors.
Added the heartbeat packet being sent.
Made changes to fit into the new package structure. Also made all classes, namely the UDPReader and FilterThread, conform to the Template class specification.
Just added a reminder :)
Added the functionality.
Took out the old code. Just need to add the new bits.
TCPReader - will perform heartbeat functions. This class only listens, it runs a TCPReaderInit thread to do the actual work.
This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, select a symbolic revision name using the selection box, or choose 'Use Text Field' and enter a numeric revision.