* removed all of the "temporary" threads used for adding timeouts to blocking socket operations:
- use the ConnectionEstablisher's thread + a SimpleTimer.TimedEvent callback to timeout socket create
- added a pool of socket handler threads (size=3 atm) for receiving any inbound sockets, which are
pulled off a queue, after which a handshake occurs to verify the other side is I2NP (along side
another SimpleTimer.TimedEvent callback in case that blocks)
this should get the last of the temporary threads (Jetty has its own thread pool for dealing with
HTTP requests, so we can ignore that thread created in the AdminRunner). The only significant
reduction in threads left is to go with either NIO or UDP, but neither are happening in the immediate
future.
* use that to render the last few lines of the wrapper log on /logs.jsp (for the on demand stack trace)
* thread creation / finalization logging
* support a hard restart (stop immediately and restart the JVM) - useful for rerunning clients.config (etc)
* systray when not supported
imported Iakin's modifications to jbigi to use the jcpuid library in detecting what jbigi implementation to load
imported and slightly updated Iakin's scripts to build jbigi for lots of architectures
(yay iakin!)
reading the router's props only if that file doesn't exist.
* by default, only log CRIT messages to the screen (the rest are sent to
the log file). this will be useful with the upcoming service controller
* refactor a common Properties helper to DataHelper.loadProps
> Message-ID: <1776.202.37.75.101.1092369510.squirrel@202.37.75.101>
> From: adam@adambuckley.net
> To: jrandom@i2p.net
>
> [...]
>
> I hereby authorize my NtpClient.java and NtpMessage.java code to be
> redistributed under the BSD license for the purpose of integration with
> the I2P project, providing that I am credited as the original author of
> the code.
>
> [...]
w00t! adam++
code migrated into core/java/src/net/i2p/time, integrated with Clock,
dropping that whole ugly pass-the-time-through-URL, and hence dropped
support for :7655/setTime.
New router.config properties to control the timestamper:
time.sntpServerList=pool.ntp.org,pool.ntp.org,pool.ntp.org
time.queryFrequencyMs=300000
time.disabled=false
So, to disable, add time.disabled=true to your router.config. It is
enabled by default.
Default router.config and startup scripts updated accordingly (since
timestamper.jar is now gone)
I marked all the empty statements with //nop
I removed unneccessary elses (ie, the if returns or throws)
I took out some casts (integral promotions/some didn't need to be there)
-- Love, shendaras
(2 in one day, w00t)
the old way fired off a new (very short lived) thread for each message received, and if two happened really really quickly, they'd both lock on the mutex and the order would be undefined
this avoids that. thanks to oOo et al for pestering me and sending in logs :)
(this is what caused the runtime errors on sun jvms but not on kaffe)
((aka i slacked and didn't test sufficiently. off with my head))
this now builds and runs fine in sun 1.3-1.5 jvms, as well as kaffe