I am a first time committer and I am using the fix to issue number 402 as a bug to learn to learn how to commit to this process. I am not sure if this is the correct way to fix this bug -- the submitter of the bug believes it is -- so please review my code with scrutiny. Thank you.
Change-Id: I6c56b7866d530e1b1c66c563f201e6d1e13d3fa9
'and' has precendence over 'or'.
both operators are left associative
parenthesized expressions are evaluated first
Parser refactored, parseAtom split up.
Change-Id: I1f194cc75df49bad9d30d041d689d8ba833076f1
Use generic queries instead of specialized index queries. This is a step
towards the publisher app, because its client will have to use generic
queries.
Context: http://camlistore.org/issue/365
Change-Id: I2781a345e024174e3bea8511b6cdc6f342d5a7c1
We still can't find their width/height or thumbnail the, but at least
we don't wedge the UI now.
Fixes camlistore.org/issue/389
Change-Id: I8af6cefa5d84e7f6e26f3920e4dd6e1d5eb8b192
Previous value of 1.6 was too small because iPhone 5's aspect ratio
is 1.78, meaning all landscape iPhone 5 photos were included in
is:pano. Same with Moto-X and probably other newer phones.
I tried 1.8, but it still "felt" too small. I think the correct
value is atleast 2.0, but perhaps larger. I don't have enough test
data in that range right now to get a good feel for it.
Change-Id: I6a3e054290d6f434afac8142a9abc68e53008229
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
Add the title:foo operator to search, to search permanodes which have a
title containing foo, case insensitively.
http://camlistore.org/issue/329
Change-Id: I661df159a4057a889a7ed110b2e724fc6e43b32b
Provides support for case-insensitive string comparisons.
The implementation needs work (e.g. substring searches do
potentially-large allocations).
Change-Id: I30f068094b4617b81aee2e8981f87f6ec2bc0000
Searching for permanodes with zero values for an attribute
returned no results due to a check that at least one value
matched. Only perform that check when a value constraint was
provided.
Change-Id: Ia25a595e4598fe682f2a85babca0b8438681a210
Work in progress, but works enough to commit now. Determing the time
of things has many TODOs, and there's some performance work to be done
(although it still appears to be instant... it just uses more CPU than
it should)
Change-Id: I4b04b5805353dfbde0b841a3a557fd0b7c297780
Also support Width and Height constraints on raw search (not yet
exposed to the expression syntax, but will be like width:<640 or
height:100-200 probably)
Change-Id: I082e3d27b5ef5c238a8e65a6b836943d9f9ff8a6
Search expressions (e.g. "tag:funny location:Portland") can now be
evaluated server-side (expr.go and expr_test.go, still nascent). Next
step is to remove this parsing and construction from the javascript UI
code.
In addition, the search result now contains a continuation token to
continue interating through the result sets in a subsequent query.
The Javascript UI should use this now instead of parsing out
modification times of things and altering the search. If there's no
continuation token, that either means the end has been reached, or
that search type doesn't [yet] support iteration. Currently only
permanode-based queries are supported at many layers, including
continuation, but will be implemented later.
For now, the web UI should send a search query "expression" value of
non-zero length but just whitespace (like a single space: " ") to get
the home page (recently-modified permanodes") because setting both to
the zero value is an input validation error. We should probably make
an expression operator to be more clear here (like "want:permanode
sort:recent"). But the empty space hack works for now.
Change-Id: I3ea92eb8c776159f53c49db1a7439a91c507940a
And quiet noisy logging on normal write failures.
We can now stress test the thumbnail generation by setting
CAMLI_DISABLE_THUMB_CACHE=1 which will make all the thumbnails in the
browsers be unique, and not write them to cache on the server.
Then, when we're happy with the thumbnails, we just increment the
thumbnailVersion string and that busts all the browser- and
server-side caches.
Change-Id: I3cda8e85ab8b1b0b2c9113f6dff613dfbf736028
benchmark old ns/op new ns/op delta
BenchmarkQueryRecentPermanodes 27987 27512 -1.70%
benchmark old allocs new allocs delta
BenchmarkQueryRecentPermanodes 99 87 -12.12%
benchmark old bytes new bytes delta
BenchmarkQueryRecentPermanodes 6433 6207 -3.51%
But will be better in practice with more blobs.
Change-Id: I4673702231c52864249329818145aad11da2b4fc
The WebSockets live queries exposed a latent locking bug: the search
code was acquiring the Corpus read lock multiple times. If a write
came in during the middle of a search, between two read locks, the
second RLock would hang (since a writer lock was pending) and then the
search and write would deadlock.
Instead, just acquire the read lock once at the beginning of the query and
never re-acquire it. For now: new "Locked" versions of all the Corpus APIs.
In the future: will probably just add the locked-or-not into the context, and make
sure all Corpus methods require a *context.Context.
Also fix two potential data races: one with LogicalCondition (which
might've raced on the scratch ss buffer, depending on the query), and
a test-only race that didn't matter in production, but was annoying in
tsan output regardless, so fixed.
More tests to follow later. Unblocking Aaron for now.
Change-Id: Ie1edcbd061235f1ef04f9b4c68b86814c84361af
Realized there was a way more elegant way to implement infinite
scroll. Now it is general to any kind of query (though not yet
to any kind of sorting, as there isn't support for continuing with
arbitrary sorts server-side).
Change-Id: I98dc627e1292524ddd8af8960c134f49ac41f337
If the JavaScript UI is open and the query you're looking at changes
due to new data arriving, the server should push the update search
results to you live, without needing to poll.
Change-Id: I00faf7737f9a459de39b21fb5226a8000feeee2b
Funny, because this one line is why I finally went and added the Context type
and started plumbing it through lots of stuff.
Change-Id: Ie419362048a485629e79725de9297fe485430d4a
1) pkg/search: documented that deletions times do not
qualify as modtimes
2) pkg/index: got rid of DeletedAt, and keyDeletes
http://camlistore.org/issue/191
Change-Id: I39578913345454d36af4599e29e7053f46577846
index in sync, both at start-up and while running and receiving blobs.
They both use the same mechanism now.
Also adds KeyId to the index and Corpus, as the next step. Plenty more
row types remain...
Change-Id: Id79955ba25dc79d5fbd94b0e5248d33dcf71d97e
keep blob metadata in memory, and start of testing all search queries in three modes:
classic index.Storage scanning, all in-memory with corpus scanned from the index.Storage,
and the in-memory corpus built up over time as blobs arrive.
Change-Id: I40536e498a63bece5bd4897cdbbd0cef78085f44
creates new package types/camtypes for misc types needed by both. might eventually go away as
search matures.
Change-Id: Ib771ead7bea39936ba478b7e5d58de997060861b
Also fixed fakeindex clock to use a time.Time.
And synchronized the fakeindex and the indextests clocks to the
same origin.
Change-Id: I986abca300d61241069132619028f470cacd61da
Start of something that builds and 'works', but barely fleshed out at all.
Likely to change drastically yet.
Change-Id: I7fba25528a341ff2dbbc4dbb579f2450d7889320
* Increase default image size a few settings
* Increase gutter between items
* Remove extraneous padding and whitepsace
* Remove unneeded gigantic heading
* Move build version into statusbar
* Change algorithm for fitting rows -- instead of preferring to clip
edges of image, instead prefer to adjust height of rows. I find it
looks more interesting visually when the widths of the images vary
more.
* Replace folder and file icon with something better looking
* Swap order of + and - buttons in toolbar, they were backward from
what is typical
Change-Id: Idfe85a813926c2c9eea774a86046df62ecacd45c
This change introduces a new index entry
to help with finding the children of a static directory.
It also fixes ResolvePrefixHop so that it takes
into account static directories, and not only collections.
This is the first step to support publishing static directories.
http://camlistore.org/issue/179
Change-Id: I5666e5caa6c782004054ae4c19a6b6119d4fda8b
misc.CountingReader moves into readerutil.
pkg/atomics is folded into pkg/types.
pkg/test/testdep is folded into pkg/test, with better name/docs.
Old cruft from pkg/webserver is deleted.
Change-Id: I3f72d8b29804254ef944995fb085837c878f79f5
images: DecodeConfig to get the predicted width
and height after EXIF correction
search&index: add GetImageInfo and use it in search
to predict the thumbnail dimensions
http://camlistore.org/issue/115
Change-Id: I358136a2ab03ea09c8f8fd2fa0dc574921c819c5
Notably, don't mix 'meta' bag keys with rest of response. Makes it easier for both Go and Closure types to not mix keys from one type with another type.
Change-Id: I65e51f2a6c236c5111b5a9b88830e1220d6b29d4
This change allows to find all roots (permanodes with the
"camliRoot" attribute) from the search.html ui page.
To achieve that, func (x *Index) SearchPermanodesWithAttr
now uses a prefix string without the query part if the
query is "".
http://code.google.com/p/camlistore/issues/detail?id=35
Change-Id: I396fba683e6e7b2296d1f0df8009c07e3c2cd09d
The serveDescribe search handler now also checks for the
thumbnails req parameter and uses populateJSONThumbnails.
As a result, the client side can directly use thumbnailSrc
from the json response.
http://code.google.com/p/camlistore/issues/detail?id=62
Change-Id: I4ff606f8d3ef291490f05cabdc66219744b53638
Required some sync work (full syncs on start, blocking full syncs on
start, and also adding a dev-only hack to force a depedency from
search -> sync, to control the handler initialization order, otherwise
publish handlers would race with the sync handler and they'd create
new "blog" and "pics" permanodes and we'd end up with duplicates).
A lot is still broken, but most stuff at least compiles now.
The directory tree has been rearranged now too. Go libraries are now
under "pkg". Fully qualified, they are e.g. "camlistore.org/pkg/jsonsign".
The go tool cannot yet fetch from arbitrary domains, but discussion is
happening now on which mechanism to use to allow that.
For now, put the camlistore root under $GOPATH/src. Typically $GOPATH
is $HOME, so Camlistore should be at $HOME/src/camlistore.org.
Then you can:
$ go build ./server/camlistored
... etc
The build.pl script is currently disabled. It'll be resurrected at
some point, but with a very different role (helping create a fake
GOPATH and running the go build command, if things are installed at
the wrong place, and/or running fileembed generators).
Many things are certainly broken.
Many things are disabled. (MySQL, all indexing, etc).
Many things need to be moved into
camlistore.org/third_party/{code.google.com,github.com} and updated
from their r60 to Go 1 versions, where applicable.
The GoMySQL stuff should be updated to use database/sql and the ziutek
library implementing database/sql/driver.
Help wanted.
Change-Id: If71217dc5c8f0e70dbe46e9504ca5131c6eeacde