Commit Graph

112 Commits

Author SHA1 Message Date
Mike Jolley c79e3ad8f1 Detect all rest endpoints, not just wc/ 2019-03-26 14:06:22 +00:00
Mike Jolley f8dded8b49 merge refactor/22762 into master 2019-03-12 13:49:10 +00:00
Mike Jolley 0877e7d8f7
Merge pull request #22954 from woocommerce/add/blocks-rest-api
Merge blocks branch: add 8 product blocks and related API endpoints
2019-03-11 15:18:20 +00:00
Mike Jolley 0e1986df7a Fix include 2019-03-08 13:11:30 +00:00
Mike Jolley 6f35239a26 Move activate/deactivate hooks to main WC class 2019-03-08 12:50:06 +00:00
Mike Jolley a3c2dcd8f2 Update from master 2019-03-08 09:50:56 +00:00
Mike Jolley 5492369fe9
Merge pull request #22857 from woocommerce/feature/marketplace-suggestions
Feature/marketplace suggestions
2019-03-07 16:39:14 +00:00
Kelly Dwan 75b5e78561 Import file to register blocks 2019-03-06 17:28:48 -05:00
Mike Jolley 16a0a3e27e Update from master 2019-03-05 19:03:01 +00:00
Mike Jolley 5af9d968e5 Update from master 2019-03-01 10:29:17 +00:00
Konstantin Kovshenin 1dad53d5e0 Update Marketplace suggestions data using WC_Queue
Schedules an update task to run as soon as possible to fetch the
suggestions data, and cache it for a week. Failures are cached for
a day.
2019-02-22 22:34:18 +03:00
Mike Jolley 07eadfeb72
Merge pull request #22760 from woocommerce/performance/webhook-loading
Performance: webhook loading
2019-02-19 09:58:06 +00:00
Mike Jolley 15bcef85e9
Merge pull request #21090 from woocommerce/fix/20937-v0.1
Added test if request is a REST API request so that cart is not loaded.
2019-02-19 09:54:48 +00:00
Peter Fabian 989fad5a7e Perhaps it does not make much sense to filter empty URI if it's REST request or not. 2019-02-18 22:52:39 +01:00
Peter Fabian 42855592e4 Updated call to reflect function change. 2019-02-18 18:59:37 +01:00
Peter Fabian ba12cf723c Renamed filter and reused the function in auth code. 2019-02-18 18:54:56 +01:00
Mike Jolley 4fd2a9f77e Update from master 2019-02-18 15:04:58 +00:00
Mike Jolley a662934355 phpcs 2019-02-18 12:53:59 +00:00
Mike Jolley d2682170fd Set woocommerce_load_webhooks_limit to no limit 2019-02-18 12:49:07 +00:00
Mike Jolley 3309276e82 Renamed table to wc_product_meta_lookup 2019-02-15 12:37:45 +00:00
Mike Jolley 7b6558e1df Correct table names and updater 2019-02-12 14:04:22 +00:00
Peter Fabian dda4cab70c Updated todo to use the common format. 2019-01-28 13:13:12 +01:00
Mike Jolley 8823559880 get rid of old term meta table 2019-01-25 20:44:25 +00:00
Peter Fabian 33584e767f Renamed function
As legacy REST API will be removed soon anyway.
2019-01-25 10:07:32 +01:00
Peter Fabian d390528d79 Updated check to only cover non-legacy REST API requests.
Updated filter name.
2019-01-24 12:06:47 +01:00
Peter Fabian 2d5fc8ef7d Merge branch 'master' into fix/20937-v0.1 2019-01-24 11:19:46 +01:00
Mike Jolley 59c97539b3 Trigger loaded hook once plugins are loaded. 2019-01-23 16:20:26 +00:00
Brent Shepherd 0708c738b9 Only load 100 webhooks per request
To avoid slowing down page loads on sites with a large numbers of
webhooks.
2019-01-18 14:30:35 +10:00
Brent Shepherd e7a5a2ab2f Only load active webhooks on each request
To avoid slowing down page loads on sites with a large number of
disabled or paused webhooks, which do not need to be loaded or
enqueued.
2019-01-18 14:29:35 +10:00
claudiulodro 3c3894b676 Bump wc_version since 3.6 development has begun 2019-01-02 12:11:35 -08:00
Tiago Noronha 3168f13d9d Skeleton for Twenty Nineteen integration 2018-11-16 16:38:05 +00:00
Peter Fabian cf3f54ec64 Made tax display in cart depend on whether customer is tax exempt. 2018-09-06 17:40:21 +02:00
Peter Fabian 0f7b470167 Added test if request is a REST API request so that cart is not loaded.
Code inspired by WC_REST_Authentication::is_request_to_rest_api, but included also legacy API .
2018-08-17 19:13:44 +02:00
Brent Shepherd d9158a8c0e Add WC_Queue and WC()->queue() wrapper for accessing it
To take care of instantiating a canonical job queue for use across
all of WooCommerce, and by 3rd party code.

Also use this new API for enqueuing webhooks instead of raw Action
Scheduler APIs.
2018-07-31 12:21:07 +10:00
Brent Shepherd 0611ff7665 Add WC_Action_Queue
As a wrapper for Action Scheduler. This implements the WC_Queue_Interface
so it can be used as WC core's job queue. Implementing WC_Queue_Interface
also means this class has more generic and appropriate job queue nomenclature
than Action Scheduler itself. For exsample, it provides a method for
non-delayed jobs, i.e. WC_Queue_Interface::add(), unlike Action Scheduler,
which requires scheduling a job for now(), which while fairly simple, is not
intuitive or immediately obvious to new comers.

This makes it both more clear and convenient to use Action Scheduler
as a simple job queue instead of just a queue for delayed jobs.
2018-07-31 12:21:04 +10:00
Brent Shepherd 8e4466c9c8 Add WC_Queue_Interface
To provide an agreed set of public methods that need to be defined
for any class wanting to act as WooCommerce's queue handler.

The require APIs support both delay jobs, by providing APIs to
schedule an action/job/event for some time in the future, and a
non-delayed job API, to add an event to the queue to run as soon
as possible.
2018-07-31 12:20:30 +10:00
Brent Shepherd e00e728f1f Merge branch 'master' into issue_18003 2018-07-25 14:41:56 +10:00
Brent Shepherd 67744b7768 Add 'woocommerce_shutdown_error' action 2018-07-13 17:08:34 +10:00
Brent Shepherd febea645f9 Log error's file and line number
To help with debugging.
2018-07-13 14:23:17 +10:00
Brent Shepherd 0c17fd49e4 Expand error logging to E_ERROR like errors
Including those triggered by code via trigger_error() and compile-time
parse errors (including those generated by Zend Scripting Engine).
2018-07-13 14:21:03 +10:00
Brent Shepherd b4c7e590b1 Load Action Scheduler lib 2018-07-06 15:41:22 +10:00
Mike Jolley 245e1768f9 Bump version so update routine gets triggered in master 2018-06-19 15:34:45 +01:00
Mike Jolley 3a673aa4e9
Merge pull request #20000 from woocommerce/update/19983
Exclude frontend include from REST API calls
2018-05-24 17:11:27 +01:00
Mike Jolley 9c2edf4983 Moves around some includes so they are included before the autoloader needs to find them 2018-05-22 12:57:48 +01:00
Mike Jolley 5de4f281fe Exclude frontend include from REST API calls 2018-05-08 12:09:04 +01:00
Boro Sitnikovski 92cd1ec0d8 Abstract out privacy class so that extensions can easily re-use it 2018-04-25 02:13:59 +01:00
Mike Jolley 9dfb91835e Merge branch 'master' into update/gdpr-order-cleanup 2018-04-18 11:21:43 +01:00
claudiulodro f9e45bea91 Bring up-to-date with master and resolve merge conflicts 2018-04-17 13:27:39 -07:00
Mike Jolley 77b73e05c8 Trigger updater 2018-04-17 16:16:11 +01:00
Mike Jolley 314d949d2c Background process to cleanup 2018-04-17 15:21:03 +01:00