Commit Graph

7202 Commits

Author SHA1 Message Date
Martijn Walraven
fdebebb7ed Replace deprecated connect.utils.parseUrl() with parseurl module
As recommended in the deprecation warning, we replace
connect.utils.parseUrl() usage with using the parseurl module directly.
2016-01-08 13:24:04 +01:00
Martijn Walraven
21ee605541 Support query parameter to avoid downloading index page when a file does not exist
When downloading files during a Cordova hot code push, we need to
detect if a file is not available instead of inadvertently downloading
the default index page.
2016-01-08 13:23:50 +01:00
Martijn Walraven
0a31dabcd6 Don't set Last-Modified based on the file date
If we serve files with a Last-Modified based on the file date, this
interferes with content-based cache validation using ETag because
clients are required to take both into account.
2016-01-08 13:21:30 +01:00
Martijn Walraven
b8a17dd97f Serve non-cacheable files with a max-age of 0 instead of a day
We previously served non-cacheable files with a max-age of a day. This was done
to avoid image flickering on page reload (see #773).
As far as I can tell, image flickering still occurs because `location.reload`
always forces validation. But switching to `location.replace` means that max-age
will actually be respected, and we don't want to cache these assets for a day
because then changes would not be visible on reloads.
2016-01-08 13:21:29 +01:00
Martijn Walraven
5d501d1793 Update send and connect dependencies for webapp package
Updating send was necessary to allow disabling setting Last-Modified,
and version dependencies required updating connect as well.
2016-01-08 13:21:29 +01:00
Martijn Walraven
5e9090c3ee Use location.replace() instead of location.reload() to avoid unnecessary asset validation
If a cached version of an asset is still fresh (depending on the `max-age`), there
is no need to send even a conditional request. Because `location.reload()` for
some reason does force validation, it makes sense to use `location.replace` instead
and improve reloading performance by avoiding unnecessary requests.
2016-01-08 13:21:29 +01:00
Martijn Walraven
dac580e212 Set ETag header to asset hash if available
Previously, the ETag header was set (by `send`) to a default value based on the
inode of the file. Using the asset hash instead allows for proper conditional
requests even after redeployments.

To take advantage of content-based caching, we also have to disable the
Last-Modified header because having this set to the file date would still make
requests conditional on the most recent deployment. This requires updating the
send dependency and is done in a separate commit.

Fixes #626.
2016-01-08 13:21:29 +01:00
Sashko Stubailo
52c67dd020 Update browser policy README 2016-01-05 15:25:17 -08:00
Michael Mason
f263ca4fea Allow middleware to set http status code
This commit allows middleware to set the status code of the http response. This will allow a server-side router to return, for example, a '404 Not Found' response. This has SEO benefits because currently search engines may index example.org/page-that-doesn't-exist because Meteor returns a 200 OK code and the normal boilerplate response body. With a proper 404 status we can still return the boilerplate to render a client side 404 template but search engines won't index the page. Instead of a hardcoded 200 response, we call res.writeHead with res.statusCode, and fallback to the default 200 code if it has not been set.
2016-01-05 11:05:53 +00:00
Mitar
5b4e1c6d39 Expose SessionDocumentView. 2016-01-04 11:00:19 -08:00
Sashko Stubailo
353e8e3a4a Merge pull request #5845 from mitar/patch-20
Allow to find the corresponding collection from the store
2015-12-29 11:01:24 -08:00
Mitar
a21be1b261 Correct argument. 2015-12-28 15:40:43 +01:00
Ben Newman
ca7c0b9a58 Make ecmascript package enable JSX syntax in .jsx files.
Bumping the version to 0.3.0 because 0.2.x is already used on the
release-1.3 branch.
2015-12-22 11:18:28 -05:00
Mitar
aee6d2ef63 Allow to find the corresponding collection from the store. 2015-12-20 12:33:54 +01:00
Avital Oliver
0376b477a5 Add clarifying comment on improved constraint solver method
Explain a recent change to CS.Input.isEqual that eliminated a very
costly set of SQLite queries against the local package catalog cache
on every app rebuild.
2015-12-16 21:18:07 -08:00
Chris Watts
312a344b8d Skips loading of the dependency cache if nothing has changed.
Excludes the cache from equality check as it shouldn't have changed.
2015-12-16 21:18:07 -08:00
Ben Newman
77b628d723 Upgrade es5-shim to fix #5759. 2015-12-09 14:10:01 -05:00
Sashko Stubailo
ccb044bb5c Merge pull request #5628 from nathan-muir/oauth-browser-policy
OAuth - remove inline javascript from popup/redirect logins
2015-12-04 11:50:57 -08:00
Sashko Stubailo
d327007a5e Merge pull request #5750 from robfallows/devel
Tinytest README - first draft
2015-12-04 09:59:30 -08:00
Ben Newman
263c45b919 Make babelHelpers.inherits even more robust against PhantomJS bugs. 2015-12-04 12:12:42 -05:00
Rob Fallows
b617f01701 Add clarity around 3rd party wrappers 2015-12-04 11:59:23 +00:00
Rob Fallows
b62932f2cf Tinytest README first draft 2015-12-04 11:52:32 +00:00
Sashko Stubailo
ff64b73253 Merge pull request #5713 from mitar/patch-17
Serve manifest.json file correctly for the main architecture
2015-12-01 14:56:39 -08:00
Sashko Stubailo
41536a9b4d Add files we forgot to commit
Fixes #5705
2015-12-01 14:53:27 -08:00
Shaunak Kishore
5f606483a6 Fix https://github.com/meteor/meteor/issues/5441 2015-12-01 03:44:20 -05:00
Mitar
53205bfcd1 Serve manifest.json file correctly for the main architecture. 2015-11-25 22:20:00 -08:00
Sashko Stubailo
a69cc4c8f2 Successfully move part of allow/deny into a separate package
And refactor Collection#insert/update/remove into real separate methods
2015-11-24 11:17:20 -08:00
Martijn Walraven
5931bcdae3 Replace _findUserByQuery with findUserByEmail 2015-11-24 12:45:19 +01:00
Martijn Walraven
436afc279d Fix accounts code that didn't respect DDPRateLimiter is only available on the server 2015-11-24 12:45:19 +01:00
Martijn Walraven
528f853649 Remove invalid nested expects from test methods 2015-11-24 12:45:19 +01:00
Simon Fridlund
5a51b5bbef Add case insensitive email lookup to forgotPassword function
Fixes #5621

While originally based on https://github.com/meteor/meteor/pull/5622, this commit has been modified by @martijnwalraven. In particular, I've cleaned up some of the test code to get rid of email variables shared between tests, and have made sure `forgotPassword` respects the passed in email and doesn't just use the first address in the user's `emails` list. Also, `Accounts.sendResetPasswordEmail` continues to expect a case sensitive email address (as do similar server functions).
2015-11-24 12:45:19 +01:00
Ben Newman
2e69f7371a Copy static property descriptors in babelHelpers.inherits.
Fixes #5624.
2015-11-20 10:56:44 -05:00
Avital Oliver
203c0aba85 Improve optimization of EJSON.clone calls in Minimongo take 3
Make it work with documents with Mongo IDs.

Also some more code reorg
2015-11-19 17:28:46 -08:00
Avital Oliver
d2a4527926 Improve optimization of EJSON.clone calls in Minimongo take 2
Support reactive calls to `count()` on cursors with skip or limit
2015-11-19 17:15:33 -08:00
Avital Oliver
f72769877e Improve optimization of EJSON.clone calls in Minimongo
* Minor code reorg/cleanup
* Do "fast pass without EJSON.clone" for updates with selector
  {_id: {$in: [...]}}
* Add an assertion that observes with skip/limit are always
  ordered (if this blows up we'll find out in the next RC)
2015-11-18 21:15:08 -08:00
Lucas Hansen
825484cbbd Fixed some bugs based on comments from the pull request 2015-11-18 12:24:18 -08:00
Lucas Hansen
11f1d884d0 Added a minimongo optimization to avoid some unecessary clones 2015-11-18 12:24:10 -08:00
Nathan Muir
ea17496ba3 OAuth - Move inline javascript for popup/redirect style logins into separate assets.
This is necessary to prevent conflict with `browser-policy-content` where inline scripts are disabled.
2015-11-18 09:55:47 +10:00
Zoltan Olah
211dd58165 Merge pull request #5586 from okland/patch-2
Polling observer driver - Allow to customize polling Interval
2015-11-17 15:32:43 -08:00
Sashko Stubailo
33eb9ee974 Merge pull request #5615 from welelay/4983-return-observeHandle
return the observeHandle in Mongo.Collection._publishCursor
2015-11-17 15:04:49 -08:00
Rishi Goomar
35f62164fa Fix docs to reflect EJSON format instead of Any
- This is to avoid any confusion of passing in any argument when it is checking for an EJSONable value
- Fixes #5657
2015-11-16 21:17:22 -06:00
Sashko Stubailo
6aa846545c Merge pull request #5663 from meteor/ddp-rate-limiter-server
Make sure it's clear that DDPRateLimiter is on the server
2015-11-16 14:06:34 -08:00
Sashko Stubailo
6baf450ee9 Make sure it's clear that DDPRateLimiter is on the server
Technically, this is a "breaking change" since code that is loaded
on client and server will now throw an error when calling DDPRateLimiter,
but the API didn't do anything on the client anyway so it's probably
more like a bug fix.
2015-11-16 10:51:59 -08:00
Ben Newman
10fa579242 Ensure Babel-generated source maps use /packages/... sources. 2015-11-11 18:03:07 -05:00
bySabi Files
4bb59df574 fix Match.Where function call 2015-11-11 19:08:41 +01:00
Sashko Stubailo
4614e7c18e Fix accounts.emailTemplates docs 2015-11-09 11:17:01 -08:00
David Burles
231bf22dda fixes bug with template subscribe 2015-11-06 16:36:07 +11:00
Eric Le Lay
dbadd6c46e return the observeHandle in Mongo.Collection._publishCursor
feature request #4983
2015-11-05 12:10:43 +01:00
ekatek
25f4859f54 change webapp interface to allow a function hook instead of a prefix
Add a bundledJsCssUrlRewriteHook function, which takes in a function and applies it
to the URL. Do not allow this on Cordova (handle that by just not calling it on Cordova).
Reimplement the bundledJsCssPrefix as a call to this function.
2015-11-04 17:35:22 -08:00
Sashko Stubailo
f0fbe353d7 Merge pull request #5601 from meteor/httpcall-undefined
Fix HTTP.call to not explode on undefined content
2015-11-03 17:55:51 -08:00