Commit graph

2542 commits

Author SHA1 Message Date
David Glasser
b7e046004c checkpoint for full query cache 2019-01-17 15:43:18 -05:00
David Glasser
18e47ea7f3 boilerplate 2019-01-16 12:42:07 -08:00
Jesse Rosenberger
355b7f3453
Update package-lock.json http resolutions for hopefully the last time.
Since the registry should be fixed, this should be the last time that we
need to search and replace those resolutions in this file to avoid merge
conflicts and unnecessary staging of `package-lock.json` changes which are
otherwise unrelated to our changes.

(Though to be clear, the registry setting always takes precedence over the
resolutions in this `package-lock.json` file so the scheme was already
strictly enforced to `http` unless the user's local npm configuration had
been manipulated to behave otherwise.)

Ref: https://npm.community/t/some-packages-have-dist-tarball-as-http-and-not-https/285/50
2019-01-15 15:42:35 +02:00
Jesse Rosenberger
9057287856
Add @types/fast-json-stable-stringify. 2019-01-15 15:33:18 +02:00
renovate[bot]
9fbf1ea677
chore(deps): update dependency yup to v0.26.7 (#2175) 2019-01-11 09:30:32 +00:00
renovate[bot]
2498dc7b1e
chore(deps): update dependency tslint to v5.12.1 (#2174) 2019-01-11 07:33:06 +00:00
renovate[bot]
ae2fa69736
chore(deps): update dependency lerna to v3.10.5 (#2173) 2019-01-11 04:33:09 +00:00
renovate[bot]
265b403196
chore(deps): update dependency lerna to v3.10.2 (#2169) 2019-01-10 04:19:39 +00:00
renovate[bot]
cc3ad8c854
chore(deps): update dependency lerna to v3.10.1 (#2166) 2019-01-09 04:17:26 +00:00
Jesse Rosenberger
9b8dc1b607
Address unaddressed feedback from #1223.
These were things I'd suggested prior to merging and I just happened to come across it again, only to find they were still outstanding:

https://github.com/apollographql/apollo-server/pull/1223
2019-01-08 20:25:18 +02:00
renovate[bot]
283013c253
chore(deps): update dependency lerna to v3.9.0 (#2163) 2019-01-08 04:24:14 +00:00
renovate[bot]
68aafbb796
chore(deps): update dependency @types/jest to v23.3.12 (#2161) 2019-01-07 10:24:38 +00:00
renovate[bot]
d069809b88
chore(deps): update dependency lerna to v3.8.5 (#2158) 2019-01-05 05:12:35 +00:00
renovate[bot]
063da8b344
chore(deps): update dependency @types/koa-router to v7.0.37 (#2157) 2019-01-05 04:30:38 +00:00
renovate[bot]
acb5984353
chore(deps): update dependency lerna to v3.8.4 (#2153) 2019-01-03 05:31:56 +00:00
renovate[bot]
6cfbd44e18
chore(deps): update dependency @types/koa-router to v7.0.36 (#2152) 2019-01-03 04:27:36 +00:00
renovate[bot]
225139129e
chore(deps): update dependency redis-mock to v0.42.0 (#2150) 2019-01-02 04:26:19 +00:00
renovate[bot]
0d28fbfd9a
chore(deps): update dependency lerna to v3.8.1 (#2148) 2019-01-01 06:19:02 +00:00
renovate[bot]
0c7d66ef39
chore(deps): update dependency @types/jest to v23.3.11 (#2147) 2019-01-01 05:16:51 +00:00
renovate[bot]
7b438b6e99
chore(deps): update dependency @types/graphql to v14.0.4 (#2146) 2019-01-01 04:27:40 +00:00
renovate[bot]
ab696e8b9b
chore(deps): update dependency husky to v1.3.1 (#2142) 2018-12-28 07:19:55 +00:00
renovate[bot]
394cb9d090
chore(deps): update dependency @types/redis to v2.8.10 (#2126) 2018-12-22 03:33:41 +00:00
renovate[bot]
ac9cb2c8a5
chore(deps): update dependency lerna to v3.8.0 (#2123) 2018-12-21 06:19:01 +00:00
renovate[bot]
ad8539c24e
chore(deps): update dependency @types/redis to v2.8.9 (#2122) 2018-12-21 04:20:56 +00:00
renovate[bot]
dd280daceb
chore(deps): update dependency @types/aws-lambda to v8.10.17 (#2121) 2018-12-21 03:21:58 +00:00
renovate[bot]
64bf1ce2cf
chore(deps): update dependency lerna to v3.7.1 (#2119) 2018-12-20 05:20:27 +00:00
renovate[bot]
0cde716a11
chore(deps): update dependency @types/node to v10.12.18 (#2118) 2018-12-20 04:19:15 +00:00
wtgtybhertgeghgtwtg
ccba8c87da Switch json-stable-stringify to fast-json-stable-stringify. (#2065)
* refactor: switch `json-stable-stringify` to `fast-json-stable-stringify`

* chore: drop `@types/json-stable-stringify`

* Update CHANGELOG.md for #2065.
2018-12-19 20:06:17 +02:00
renovate[bot]
bb2fc6d862
chore(deps): update dependency husky to v1.3.0 (#2116) 2018-12-19 05:25:38 +00:00
renovate[bot]
4add1c3a74
chore(deps): update dependency @types/node to v10.12.17 (#2115) 2018-12-19 04:24:45 +00:00
renovate[bot]
6dfd6a3b70
chore(deps): update dependency @types/hapi to v17.8.2 (#2114) 2018-12-19 03:24:50 +00:00
renovate[bot]
eeb54a41c6
chore(deps): update dependency @types/aws-lambda to v8.10.16 (#2113) 2018-12-19 02:46:07 +00:00
renovate[bot]
a8980494bf
chore(deps): update dependency tslint to v5.12.0 (#2112) 2018-12-19 02:41:09 +00:00
Jesse Rosenberger
8a1f99916d
Merge pull request #2109 from apollographql/abernix/caching-tweak-prep-two
Improve InMemoryLRUCache implementation.
2018-12-18 11:15:00 +02:00
Jesse Rosenberger
fa63116cd7
Merge branch 'master' into abernix/caching-tweak-prep-two 2018-12-18 11:13:26 +02:00
Jesse Rosenberger
2b50e149b0
caching: InMemoryLRUCache support for ttl, much like Redis/Memcached.
This also re-enables the Expiration tests for this library, though I think I
will continue to leave the testsuite decomposed into more granular methods
for readability and future growth.

Note that this doesn't implement the same default `300` second TTL as the
other Memcache and Redis implementations currently do (a very debatable
default we should re-consider in the future).
2018-12-18 10:55:38 +02:00
Jesse Rosenberger
098c893990
nit: Use the term value rather than data for Key + *Value* stores.
Super nitty, but they are KeyValue stores, not KeyData stores.
2018-12-18 10:55:37 +02:00
Jesse Rosenberger
c7f6b43234
tests: Change apollo-server-caching test-suite to support InMemoryLRUCache. 2018-12-18 10:55:36 +02:00
Jesse Rosenberger
d53f361c54
cache: Implement flush method for InMemoryLRUCache.
This implements the `flush` method, which is currently supported by both
Memcached and Redis, into the `InMemoryLRUCCache` cache.
2018-12-18 10:55:36 +02:00
Jesse Rosenberger
f3981b76a4
Adjust InMemoryLRUCache to allow non-string values via generics.
While it is certainly our current implementation, I'm not sure that the true
spirit of an in-memory key-value store is to only map strings to other strings.

While enforcing `<string, string>` might be necessary for some distributed
cache stores, it seems we shouldn't enforce it for `InMemoryLRUCache`.

By changing the `KeyValueCache` to default to `string` but allow other
options, we can allow the user to decide exactly how the RHS of this store
should be typed.

This does require a bit more flexible implementation of the `length`
calculator which is used for cache ejection, but that implementation will
become immediately useful when we start storing parsed ASTs in this KV store.
2018-12-18 10:55:35 +02:00
Jesse Rosenberger
8ad2bdda75
Merge pull request #2108 from apollographql/abernix/caching-tweak-prep
chores: Request pipeline readability/DRYing.
2018-12-18 10:54:43 +02:00
Jesse Rosenberger
5a50e1bab2
chore: DRY-up the error response logic with a sendErrorResponse helper.
Introduces a helper function to DRY-up the increasingly-repeated pattern of
sending an error response in the event of request errors.
2018-12-18 10:43:19 +02:00
Jesse Rosenberger
705615828f
chore: Effectively identical but more intuitive path for validationDidEnd.
Rather than crutching on the `return`, this logic reads more concisely with
a full `if` / `else` pattern.

I say this because two people looked at it and weren't immediately aware,
which really shouldn't be the case from such a brief piece of code.
2018-12-18 10:43:18 +02:00
Jesse Rosenberger
89d20b39db
chore: Simplify logic for caching persisted query asynchronously.
This method is so large this was just low-hanging fruit along a path of
potential opportunities.
2018-12-18 10:43:18 +02:00
Jesse Rosenberger
6b47f6f3e6
chore: DRY-up runQuery test interface via Pick'd GraphQLOptions. (#2107)
This test harness is intended to be relatively temporary, but it seems
fruitful to start picking from where these types are already defined rather
than re-implementing them in multiple places.

This change came up in a larger feature implementation and should otherwise be
a no-op but was worth surfacing as its own commit in case that feature never
lands.
2018-12-18 10:42:33 +02:00
Jesse Rosenberger
7797dcc5ab
Update CHANGELOG.md 2018-12-17 13:21:03 +02:00
Jesse Rosenberger
0bf209a5fb
Update CHANGELOG.md
For increased awareness: https://github.com/apollographql/apollo-server/issues/2099
2018-12-17 13:20:12 +02:00
renovate[bot]
9b8c8b05a0
chore(deps): update dependency apollo-link-http to v1.5.9 (#2102) 2018-12-15 05:31:08 +00:00
renovate[bot]
5ca283def9
chore(deps): update dependency apollo-link to v1.2.6 (#2101) 2018-12-15 04:33:47 +00:00
renovate[bot]
3ed765f455
chore(deps): update dependency husky to v1.2.1 (#2098) 2018-12-14 08:27:58 +00:00