Commit Graph

1329 Commits

Author SHA1 Message Date
Brad Fitzpatrick 2a3d84824a jsonsign: update old code to use fmt.Errorf
Change-Id: Iedd969e336dd02af6b3bc60590bfc7aa9ea9c89e
2014-01-28 21:52:36 -08:00
Brad Fitzpatrick 0052ec2366 webserver: also log req.RemoteAddr in verbose mode
Change-Id: I83e2ddcb74208de61d5392a519b69d147f427c1d
2014-01-28 12:31:20 -08:00
Dustin Sallings 6f5b0151f2 client: don't remember discovery errors permanently
fixes camlistore.org/issue/348

Change-Id: I689319cd03dbbcc035698a2ce58d4557c28d9ac0
2014-01-27 16:45:18 -08:00
Brad Fitzpatrick a70b554023 pkg/client, camput: don't stat each chunk before uploading
Trust the have cache for skipping uploads.

Reduces total number of HTTP requests.

Also, set Transport's MaxIdleConnsPerHost to be the same as
our HTTP concurrency level, to not keep re-creating TCP
connections.
2014-01-27 16:07:15 -08:00
Brad Fitzpatrick 798cd5e9d2 client: use syncutil.Gate instead doing it by hand 2014-01-27 14:08:05 -08:00
Brad Fitzpatrick 3d3e702a16 Merge branch 'master' of https://camlistore.googlesource.com/camlistore 2014-01-26 22:05:16 -08:00
Brad Fitzpatrick 0072a5b325 client/android: instrument memory usage.
also try to GC and return memory to OS every 5 seconds, but
that barely makes a dent in the real problem.

more later.

Change-Id: I2979e099121bdcb8578124b1c45714313cc2ec09
2014-01-26 22:05:02 -08:00
Brad Fitzpatrick f4d9fab966 schema: don't use ReceiveBlob directly
Change-Id: I268165cdaa4e4c8fea720a57a58cccc0f934cdf2
2014-01-26 21:56:39 -08:00
Brad Fitzpatrick c97c0d48b3 osutil: add MemUsage func
Change-Id: I4a0cbde782077c5b34caefd9b6bdb99bc659c2c9
2014-01-26 21:56:16 -08:00
Brad Fitzpatrick b15cde9bce Merge "pkg/search: Add durationms to MediaTagConstraint comment." 2014-01-26 18:45:33 +00:00
Daniel Erat ef6e0bc696 pkg/search: Add durationms to MediaTagConstraint comment.
Change-Id: I8c097c2c88afaf01b9eb0f62072f5e68bddf5ca0
2014-01-25 17:22:33 -08:00
Brad Fitzpatrick 1442639257 Merge "Added syncutil.Once" 2014-01-25 22:05:56 +00:00
Dustin Sallings 4fb88a2120 Added syncutil.Once
Change-Id: I83744a3646bac449934ab0dc6477b4dd1c351e5e
2014-01-25 12:04:47 -08:00
Brad Fitzpatrick de99ea69cd Merge branch 'master' of https://camlistore.googlesource.com/camlistore 2014-01-25 11:04:12 -08:00
Brad Fitzpatrick 92b23e391d search: basic lexer to supported quoted tokens in search expressions
Change-Id: I6c8c37e3b27ab947623bbe7431352a14aa029839
2014-01-25 11:04:02 -08:00
Brad Fitzpatrick 80f6c39c20 Merge "pkg/index: Index audio duration." 2014-01-25 18:42:09 +00:00
Daniel Erat 5603ea8e0d pkg/index: Index audio duration.
Add pkg/media with code to calculate MPEG audio duration.
Index it in a "durationms" property.

Change-Id: Ifb6251657cadc365ef3f5667a0512fde17575560
2014-01-25 10:40:06 -08:00
Brad Fitzpatrick 74479632a2 Merge branch 'master' of https://camlistore.googlesource.com/camlistore 2014-01-25 09:27:00 -08:00
Brad Fitzpatrick 466f166817 geocode: if Google returns a whole-world geometry, use its viewport instead
Change-Id: Iec4abf2ad117ab37a3f23fedc12e6e7b3943fc4e
2014-01-25 09:26:18 -08:00
Tommi Virtanen 6cda29582b third_party: Switch FUSE library to bazil.org/fuse
import bazil.org/fuse at f6649cd46fb76b1e04ba9eeffb773cb189278d31
remove code.google.com/p/rsc/fuse.

Huge thanks to Tommi Virtanen for the fuse support.

Change-Id: I44b95ac1ea344648593c7376f83ca675a56077b3
2014-01-24 13:28:08 -08:00
mpl a629124f44 Merge "pkg/types: add InvertedBool" 2014-01-23 21:58:12 +00:00
mpl 20b9f5d6f1 pkg/types: add InvertedBool
Will be needed for json tagged serverconfig in subsequent commit.

http://camlistore.org/issue/339

Change-Id: I41ae6e9918b23eb9bdb471e402de0415f3499dc3
2014-01-23 22:54:18 +01:00
mpl 1373456c25 Merge "rename pkg/serverconfig to pkg/serverinit" 2014-01-23 21:25:26 +00:00
Tamás Gulácsi 9feb32a329 Add some common file signatures to magic.
Change-Id: I428933fdb5bb987113ae1bbd1161eca4c477b426
2014-01-23 21:55:37 +01:00
Brad Fitzpatrick c35f1d1afe Merge "pkg/index: Index more music-related properties." 2014-01-23 16:33:08 +00:00
mpl 448f266d72 rename pkg/serverconfig to pkg/serverinit
To avoid awkwardness with future pkg/types/serverconfig

http://camlistore.org/issue/339

Change-Id: If8a00941cdc269d6bcfe0f76c596154d5969bf0d
2014-01-23 17:18:46 +01:00
Daniel Erat 404548d31a pkg/index: Index more music-related properties.
Add disc and mediaref (a hash of the audio portion of the
file).

Also relocate taglib code to
third_party/github.com/hjfreyer/taglib-go.

Change-Id: I58364f525b787484af894663125163095256d7c6
2014-01-22 21:25:05 -08:00
Brad Fitzpatrick 1b7ac2da01 test: add TODO to simplify 2014-01-21 14:18:11 -08:00
Daniel Erat 704d3c6bfc pkg/index: Rename audiotag to mediatag.
Also fix up keys and values and add tests.

Change-Id: I7e6c5c4315705442e3517456f2ba16419af49f2f
2014-01-20 21:46:39 -08:00
Brad Fitzpatrick 5b03c3f8fb search, index: let media tags be searchable too.
git push from Dolores Park. Sorry, no tests. Dan Erat will tell me if
this doesn't work.

Change-Id: I557cc3d07983390b8a15b7756ee0825fced2f503
2014-01-20 15:47:36 -08:00
Brad Fitzpatrick 9abba638a0 Add new environment variables for setting client identity for use with test.World.
Testing clients should now use CAMLI_CLIENT_IDENTITY,
CAMLI_DISABLE_CLIENT_CONFIG_FILE (both new) and existing
CAMLI_SECRET_RING, set using the new test.World accessors.

Change-Id: I9fc0571b008f033674466bbc98129ae1919a0640
2014-01-20 13:54:42 -08:00
Brad Fitzpatrick a384ff188d Get rid of CAMLI_DEV_KEYBLOBS / keyblobs / etc.
Fixes camlistore.org/issue/277

Change-Id: I7f380f9d18785f600fa0c442d5a19cd118782788
2014-01-20 13:47:08 -08:00
Brad Fitzpatrick d5ec2925dd namespace: finish tests
Change-Id: Ib34364473e407e78fd691256ad1afe8c810911a9
2014-01-20 13:08:37 -08:00
Brad Fitzpatrick 31125295a4 test: fix enumerate bug in in-memory storage when double-uploaded
Change-Id: I7e6abb1c9dfc61f39fa9d315857bf7aeb13b6b59
2014-01-20 13:07:20 -08:00
Brad Fitzpatrick 2b06004813 Merge "diskpacked: keep fd open to every pack file." 2014-01-20 19:59:58 +00:00
Bill Thiede 5c884e52ca diskpacked: keep fd open to every pack file.
Bytes read/writen per pack file, as well as per configured diskpacked
configuration are now available as expvars.

Also add reader stat helpers to pkg/types and updated the original
user in server/image.go

Change-Id: Ifc9d76c57aab329d4b947e9a4ef9eac008bc608d
2014-01-20 10:50:42 -08:00
Brad Fitzpatrick aebc8f00c6 cond: add test using storagetest
Change-Id: Iffd987de42d82e1c19ff2c984ff3d2f01824e34c
2014-01-20 10:37:23 -08:00
Brad Fitzpatrick bb5059bafd namespace: implementation, and initial basic tests using storagetest.
Change-Id: Ib53822fb530f9a1bd2a3c0658120639d5bf4426a
2014-01-19 22:47:35 -08:00
Brad Fitzpatrick b0ae1a55eb replica: add test using storagetest + fix RemoveBlobs bug found with it
Change-Id: I6f33a212d0d9b7fc7eca0fe908da2b3521183fc4
2014-01-19 22:47:02 -08:00
Brad Fitzpatrick d341375188 Start of 'namespace' blob storage target.
Change-Id: I7b6f1a9eea1a7b37482e890238dabc9f1a39c4a5
2014-01-19 15:17:31 -08:00
Brad Fitzpatrick 8e92ad3c71 cond: clean-up and start of tests
Change-Id: Ie7397bde5650f997c9d6abcc1040838b55fccedf
2014-01-19 15:06:55 -08:00
Brad Fitzpatrick f015c227f0 serverconfig: allow marking handlers as internal, so they're not accessible over HTTP
Change-Id: I37190e90fbc2560c07f742270c827f6025a2fb6f
2014-01-19 14:50:34 -08:00
Brad Fitzpatrick 4d9e797ae1 test: fix probing test server. do HTTP request. TCP port will always be listening (by parent)
Change-Id: I3d2bac6419f5e5e0362f549a5aca7b7ccbf967e6
2014-01-19 14:35:05 -08:00
Brad Fitzpatrick c9fd454875 Merge branch 'master' of https://camlistore.googlesource.com/camlistore 2014-01-19 10:14:53 -08:00
Brad Fitzpatrick e29c43bfde replica: test minWritesForSuccess
Change-Id: I5c845e99b1c440c35bfb7a5a7865176fd72ae031
2014-01-18 22:53:03 -08:00
Brad Fitzpatrick cfeeda0fa9 replica: change receive strategy, fixing a TODO, and start of tests
Change-Id: I74c1206ce4bb34ddffe2601cf95fce393116c303
2014-01-18 21:16:24 -08:00
Brad Fitzpatrick cbed03b187 Merge "fs: fix crash setting xattr on a root" 2014-01-19 02:27:12 +00:00
Aaron Boodman 8387acb5ce Merge "Trial fix for infinite piggie bug." 2014-01-18 22:45:11 +00:00
Brad Fitzpatrick 0c1a271d38 When caching resized images, don't use a file schema blob and lots of little
chunks when the size of the resized image is under 16 MB.

Also add some more expvars counters.

Change-Id: I769247edf3819ca95669bdf9a1c8d3876c54095b
2014-01-18 10:12:29 -08:00
Brad Fitzpatrick 1cbd7365b4 Fix thumbnail cache filename fmt pattern bug.
I noticed thumbnail files named like:

{"camliVersion": 1,
  "camliType": "file",
  "fileName": "scaled:sha1-da55749abffc24004177c32e8ea00687044910b8:2000x256:tv%!d(string=2)",
  "parts": [
    {
      "blobRef": "sha1-82810ad435f5354e4d8ad358a011bc221053b1bb",
      "size": 11239
    }
  ]
}

Change-Id: I3bc729917c226622e70fb662e0413eeacfda6d93
2014-01-18 09:18:13 -08:00