Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[KZL-522] Collection specifications methods cloisoned to a collection #1300

Merged
merged 6 commits into from
May 20, 2019

Conversation

thomasarbona
Copy link
Contributor

What does this PR do ?

Validate specifications:

  • add new endpoint http://kuzzle:7512/<index>/<collection>/_validateSpecifications
  • deprecate the previous endpoint http://kuzzle:7512/_validateSpecifications

Update specifications:

  • add new endpoint http://kuzzle:7512/<index>/<collection>/_specifications
  • deprecate the previous endpoint http://kuzzle:7512/_specifications

How should this be manually tested?

  • Step 1 : call the validate specifications with the new endpoint
  • Step 2 : same with update specifications

@codecov
Copy link

codecov bot commented May 15, 2019

Codecov Report

Merging #1300 into 1-dev will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##            1-dev    #1300      +/-   ##
==========================================
+ Coverage   93.84%   93.85%   +<.01%     
==========================================
  Files          98       98              
  Lines        6857     6862       +5     
==========================================
+ Hits         6435     6440       +5     
  Misses        422      422
Impacted Files Coverage Δ
lib/config/httpRoutes.js 100% <ø> (ø) ⬆️
lib/api/controllers/collectionController.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a032190...e3e4095. Read the comment docs.

@codecov
Copy link

codecov bot commented May 15, 2019

Codecov Report

Merging #1300 into 1-dev will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##            1-dev    #1300      +/-   ##
==========================================
+ Coverage   93.84%   93.85%   +<.01%     
==========================================
  Files          98       98              
  Lines        6857     6862       +5     
==========================================
+ Hits         6435     6440       +5     
  Misses        422      422
Impacted Files Coverage Δ
lib/config/httpRoutes.js 100% <ø> (ø) ⬆️
lib/api/controllers/collectionController.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a032190...d852ee7. Read the comment docs.

lib/api/controllers/collectionController.js Outdated Show resolved Hide resolved
test/api/controllers/collectionController.test.js Outdated Show resolved Hide resolved
test/api/controllers/collectionController.test.js Outdated Show resolved Hide resolved
test/api/controllers/collectionController.test.js Outdated Show resolved Hide resolved
test/api/controllers/collectionController.test.js Outdated Show resolved Hide resolved
@thomasarbona thomasarbona requested a review from Aschen May 17, 2019 08:46
@@ -153,7 +153,10 @@ module.exports = [
{verb: 'post', url: '/credentials/:strategy/_me/_create', controller: 'auth', action: 'createMyCredentials'},
{verb: 'post', url: '/credentials/:strategy/_me/_validate', controller: 'auth', action: 'validateMyCredentials'},

/* DEPRECATED - will be removed in v2 */
Copy link
Contributor

@scottinet scottinet May 17, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(open to debate)

since this deprecation notice is introduced so late in the v1, I wonder if this shouldn't stay for the next major version
Usually, you deprecate something during a major, it stays in the next one, and (sometimes) removed after that

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since there is only very few people that use the validation module I think we can remove this route.
If we setup a compat configuration option (cf trello) users will be able to keep deprecated route if they want but IMHO it's better to push users to embrace change

@alexandrebouthinon alexandrebouthinon merged commit e612f51 into 1-dev May 20, 2019
@alexandrebouthinon alexandrebouthinon deleted the KZL-522-collection-spec-cloisoned branch May 20, 2019 09:49
thomasarbona added a commit to kuzzleio/documentation that referenced this pull request Jun 5, 2019
## What does this PR do?

- Update the API documentation because of this PR: kuzzleio/kuzzle#1300

### How should this be manually tested?

  - Step 1 : `npm install && npm run dev`
  - Step 2 : visit http://localhost:8080/core/1/api/api-reference/controller-collection/validate-specifications/
  - Step 3 : visit http://localhost:8080/core/1/api/api-reference/controller-collection/update-specifications/
@Aschen Aschen mentioned this pull request Jun 14, 2019
Aschen added a commit that referenced this pull request Jun 14, 2019
Release 1.8.0

Bug fixes

    [ #1311 ] Fix promise leaks (scottinet)
    [ #1298 ] Fix disabled protocol initialization (Aschen)
    [ #1297 ] Fix timeouts on plugin action returing the request (benoitvidis)
    [ #1288 ] Fix an error when trying a non-partial bulk update (scottinet)
    [ #1286 ] Allows bulk inserts on aliases (benoitvidis)
    [ #1282 ] Scan keys on redis cluster (benoitvidis)
    [ #1279 ] Users must be authenticated to use auth:logout (scottinet)

New features

    [ #1315 ] Add the new Vault module to handle encrypted application secrets (Aschen)
    [ #1302 ] Add write and mWrite (Aschen)
    [ #1305 ] Add pipes & hooks wildcard event (thomasarbona)

Enhancements

    [ #1318 ] Add a maximum ttl to auth:login (benoitvidis)
    [ #1301 ] Upgrade the WebSocket libraries (scottinet)
    [ #1308 ] Events triggering refactor (scottinet)
    [ #1300 ] Collection specifications methods cloisoned to a collection (thomasarbona)
    [ #1295 ] Improve validation error messages (benoitvidis)
    [ #1292 ] Throw an error when the realtime controller is invoked by plugin developers (benoitvidis)
    [ #1257 ] Add ability to define mapping policy for new fields (Aschen)
    [ #1291 ] Fix --help on subcommands (Yoann-Abbes)
    [ #1289 ] Handle ping/pong packets (scottinet)
    [ #1273 ] Fix incomplete access logs (scottinet)

Others

    [ #1317 ] Add ps dependency to plugin-dev Docker image for pm2 (benoitvidis)
    [ #1312 ] Check that .kuzzlerc.sample is well-formed (scottinet)
    [ #1299 ] Add Kuzzle Nightly & Redis 3 and 4 test (alexandrebouthinon)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants