Commit Graph

852 Commits

Author SHA1 Message Date
Michael Bayne 0fd022d9cc Fix issues with installation and unpacking.
When the resource installation phase was added (downloading to _new files and
then moving them over top of the originals once they were validated), this
broke handling of unpacked resources.

Because we don't explicitly track whether a given version of a resource has
been unpacked (would be tricky) we try to piggy back on the download validation
process. But we validate before we install and we need to unpack after we
install, so for resources that are to be installed, we now also unpack and mark
as valid after the install is complete.

Closes #88.
2017-11-17 15:07:26 -08:00
Michael Bayne 065728276f Move unpackJar into Getdown's FileUtil.
Convert unpackJar and unpackPackedJar200 to throwing exceptions on failure
instead of catching, logging and returning booleans.
2017-11-17 14:59:12 -08:00
Michael Bayne 5925a6b57c Move noInstall() check into install(). 2017-11-17 13:59:17 -08:00
Michael Bayne 3b3e8be165 Order logic a little less weirdly. 2017-11-17 13:57:46 -08:00
Michael Bayne 9e95ef3ea2 Apply connect and read timeouts uniformly.
Also use a 5 second connect/read timeout when detecting a proxy, to avoid
lengthy stalls.
2017-10-23 18:13:19 -07:00
Michael Bayne 7879a408f8 Remove Bang & TT2.
Bang is only shipped via Steam now and TT2 seems to have died.
2017-09-17 10:43:49 -07:00
Michael Bayne 1580a0b36f Note 1.6.4 release and JVM version requirements.
Handy that we moved to Java 6 with the 1.6 series and can move to Java 7 with
the 1.7 series.
2017-09-17 10:41:10 -07:00
Michael Bayne 167ea2c5d5 Use some diamond operators just for kicks. 2017-09-17 10:31:58 -07:00
Michael Bayne d8fa95e15c Move to Java 1.7 minspec. 2017-09-17 10:31:47 -07:00
Michael Bayne 23a44e661e [maven-release-plugin] prepare for next development iteration 2017-09-17 10:23:34 -07:00
Michael Bayne 20c2304137 [maven-release-plugin] prepare release getdown-1.6.4 2017-09-17 10:23:25 -07:00
Michael Bayne 93f313c1d8 Fix Javadoc. 2017-09-17 10:11:41 -07:00
Michael Bayne c50b2d6b16 Travis seems to no longer support JDK6.
Maybe with the next Getdown release, I'll drop JDK6 support as well.
2017-09-17 10:04:22 -07:00
Michael Bayne 1f919ca9c9 Parallelize digest(2).txt computation.
Ad-hoc test on MBP with four-core i7 takes us from:

digest.txt: Computed digests [rsrcs=344, time=1055ms]
digest2.txt: Computed digests [rsrcs=344, time=2068ms]

to

digest.txt: Computed digests [rsrcs=344, time=328ms]
digest2.txt: Computed digests [rsrcs=344, time=832ms]
2017-09-17 09:52:48 -07:00
Michael Bayne dcd74f1bd9 Parallelize resource verification.
Ad-hoc testing with ~320MB of resources reduces verification time from
~2400ms to ~800ms on MBP with four-core i7.
2017-09-17 09:34:45 -07:00
Michael Bayne b39e59550f Make Resource comparable. 2017-09-17 09:29:06 -07:00
Michael Bayne 99a093a1c7 Allow any collection of resources to be downloaded. 2017-09-17 09:26:13 -07:00
Michael Bayne bc3252dbf0 Default to a 30s read timeout during downloads.
This is configurable via a system property -Dread_timeout=N.
2017-08-15 09:32:13 -07:00
Michael Bayne 19ed330a8d Always install a (valid) _new file if we have one.
Thanks to deepfreeze32 for the suggested fix.
2017-08-15 08:52:39 -07:00
Michael Bayne 454a8759af Apply strict comments to digest.txt file as well. 2017-07-03 09:21:53 -07:00
Michael Bayne b1c85ddb2e Restructure code to be less wonky. 2017-06-29 10:37:51 -07:00
Michael Bayne 1922919995 Formatting tweaks. 2017-06-29 09:31:01 -07:00
Michael Bayne 7c7cdbbe8e Merge pull request #85 from Artelys/master
bugfix when getdown stopped after downloading before installing
2017-06-29 09:29:12 -07:00
Paul-Yves Lucas e9774a0385 correcting bug when a localNew resource was here but not the local (if the app was stopped in the middle of dl for ex), it was valid and not installed, now it put in the _toBeInstalledResouces list for proper installation 2017-06-29 10:57:57 +02:00
Michael Bayne 61534b569c Added support for "strict comments".
In this mode, Getdown only treats a # as a comment starter in column zero. All
other #s are ignored. You enable it by putting:

strict_comments = true

in your getdown.txt file. Yes the same file that has to be parsed with or
without strict comments. If we see that, we reparse the file with strict
comments.
2017-06-28 17:58:17 -07:00
Michael Bayne 02975c107e Replace SysPropsTest with VersionUtilTest.
As pointed out by soapyfrog, depending on info from the JVM running the
test is fragile and not a good idea.

Fixes #84.
2017-04-25 08:43:19 -07:00
Michael Bayne 4855057b2a [maven-release-plugin] prepare for next development iteration 2017-04-23 07:20:55 -07:00
Michael Bayne eb7b0b9511 [maven-release-plugin] prepare release getdown-1.6.3 2017-04-23 07:20:46 -07:00
Michael Bayne a884284cf3 Apparently prereqs are not for regular projects.
I was misled by the check upgrade plugin which complained about a lack
of prereqs.
2017-04-23 07:08:15 -07:00
Michael Bayne e66b8fc2eb Fix error parsing code_cache_retention_days.
Fixes #82.
2017-04-10 14:03:01 -07:00
Michael Bayne 9e23a426a6 Fix backward logic re: use of code cache. 2017-02-22 08:45:20 -08:00
Michael Bayne 4ac9990785 Apparently jspawnhelper moved. 2017-02-14 11:01:44 -08:00
Michael Bayne 1f0897dacc Reference 1.6.2 release. 2017-02-12 09:24:25 -08:00
Michael Bayne 0eaf144a1d [maven-release-plugin] prepare for next development iteration 2017-02-12 09:23:07 -08:00
Michael Bayne c45588e2ac [maven-release-plugin] prepare release getdown-1.6.2 2017-02-12 09:22:58 -08:00
Michael Bayne e60b95cf2d Install the local JVM resource before unpacking.
Fixes #78.
2017-02-12 09:20:58 -08:00
Michael Bayne 0b5c82a116 Get the absolute path to a local VM to avoid CWD problems. 2017-02-12 09:20:22 -08:00
Michael Bayne 1da36ace83 Added override_appbase system property.
This can be used to completely override the appbase via the installer in
situations where you want to build a deployment once, but then potentially
serve it from some other webserver.
2017-02-12 08:47:57 -08:00
Michael Bayne 977b6de7b4 Reference 1.6.1 build. 2017-02-12 07:52:54 -08:00
Michael Bayne 9fe6ff9472 [maven-release-plugin] prepare for next development iteration 2017-02-12 07:47:44 -08:00
Michael Bayne c3de781075 [maven-release-plugin] prepare release getdown-1.6.1 2017-02-12 07:47:37 -08:00
Michael Bayne 8a36b101bb Fix javadoc error. 2017-02-12 07:46:51 -08:00
Michael Bayne 84af080b0d Encode paths for download more robustly. 2017-02-12 07:38:30 -08:00
Michael Bayne a5ad6edf3c Bias pair parsing toward key in digest.txt.
In that file we have:

filename = hex_encoded_hash

The hex_encoded_hash will never contain = but the filename could
conceivably contain =, so for that file we split on the last = instead
of the first.

Everywhere else we continue to split on the first = because that makes
more sense.
2017-02-02 19:24:16 -08:00
Michael Bayne 173986c8be Only ignore things created by this project's standard build.
If you use an IDE that generates random cruft in the project directory,
create your own global .gitignore:

http://stackoverflow.com/questions/7335420/global-git-ignore
2016-12-22 08:13:46 -08:00
Michael Bayne 1b5e4aae11 Merge pull request #76 from Artelys/master
bugfix for ProgressAggregator
2016-12-22 08:13:30 -08:00
Paul-Yves Lucas b1c41b5e70 Merge remote-tracking branch 'artelysGithub/master' 2016-12-06 14:16:22 +01:00
Paul-Yves Lucas 256e0933aa correcting bug in progressaggregator where progress event updated the _sizes array instead of globabl _progress array (progressbar now progress more fluidly) 2016-12-06 14:09:30 +01:00
Michael Bayne 1053a11c46 Mark jspawnhelper as executable.
Closes #74.
2016-11-11 07:57:36 -08:00
Paul-Yves Lucas a1a7f416ff Merge remote-tracking branch 'origin/master' 2016-11-10 09:59:47 +01:00