Make max # of open file descriptors (RLIMIT_NOFILES) configurable

Configured as "MaxFileDescriptors" property in server config.
Default value is 5000, so even without setting the property you get
more than the OS gives you by default.
NOTE: This commit may not build on Windows due to using the syscall
package, which is platform-dependent.
Fixes #218
Improved call to Setrlimit (respect previous Max)

Also took out ulimit call in run.sh script
For #218
Fixed a channelCache logic error

Fixed the case where prependChanges is called with an empty array of
changes (don't crash, and possibly use changesValidFrom to our advantage.)
Fixes #290
Merge branch 'master' into stable