Skip to content

Add batch user creation step for speeding up the requests#35403

Merged
DeepDiver1975 merged 1 commit into
masterfrom
batch-request
Jun 13, 2019
Merged

Add batch user creation step for speeding up the requests#35403
DeepDiver1975 merged 1 commit into
masterfrom
batch-request

Conversation

@dpakach

@dpakach dpakach commented Jun 3, 2019

Copy link
Copy Markdown
Contributor

Description

Add new step for user creation using batch requests to speed up the ci

Related Issue

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Database schema changes (next release will require increase of minor version instead of patch)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests only (no source changes)

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:

Open tasks:

  • Backport (if applicable set "backport-request" label and remove when the backport was done)

@skshetry

skshetry commented Jun 3, 2019

Copy link
Copy Markdown
Contributor

Can you make this run by default? Would be good to find what difference does this make.

@codecov

codecov Bot commented Jun 3, 2019

Copy link
Copy Markdown

Codecov Report

Merging #35403 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master   #35403   +/-   ##
=========================================
  Coverage     65.66%   65.66%           
  Complexity    18666    18666           
=========================================
  Files          1221     1221           
  Lines         70597    70597           
  Branches       1288     1288           
=========================================
  Hits          46358    46358           
  Misses        23862    23862           
  Partials        377      377
Flag Coverage Δ Complexity Δ
#javascript 53.69% <ø> (ø) 0 <ø> (ø) ⬇️
#phpunit 67.04% <ø> (ø) 18666 <ø> (ø) ⬇️

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 666e084...2aa2d37. Read the comment docs.

@codecov

codecov Bot commented Jun 3, 2019

Copy link
Copy Markdown

Codecov Report

Merging #35403 into master will decrease coverage by 0.32%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #35403      +/-   ##
============================================
- Coverage     65.93%   65.61%   -0.33%     
  Complexity    18735    18735              
============================================
  Files          1160     1221      +61     
  Lines         63470    70793    +7323     
  Branches          0     1288    +1288     
============================================
+ Hits          41852    46449    +4597     
- Misses        21618    23967    +2349     
- Partials          0      377     +377
Flag Coverage Δ Complexity Δ
#javascript 53.69% <ø> (?) 0 <ø> (?)
#phpunit 66.97% <ø> (+1.03%) 18735 <ø> (ø) ⬇️
Impacted Files Coverage Δ Complexity Δ
lib/private/DB/PostgreSqlMigrator.php 0% <0%> (-100%) 6% <0%> (ø)
...ilder/ExpressionBuilder/PgSqlExpressionBuilder.php 0% <0%> (-88.89%) 3% <0%> (ø)
lib/private/DB/AdapterPgSql.php 0% <0%> (-85.72%) 2% <0%> (ø)
lib/private/Files/Storage/DAV.php 80.46% <0%> (-9.1%) 0% <0%> (ø)
lib/private/DB/Migrator.php 53.01% <0%> (-2.41%) 30% <0%> (ø)
lib/private/legacy/db.php 70.51% <0%> (-1.29%) 33% <0%> (ø)
lib/private/legacy/util.php 67.17% <0%> (-1.03%) 240% <0%> (ø)
apps/dav/lib/CardDAV/CardDavBackend.php 83.05% <0%> (-0.24%) 86% <0%> (ø)
apps/dav/lib/CalDAV/CalDavBackend.php 80.52% <0%> (-0.14%) 179% <0%> (ø)
lib/private/DB/MDB2SchemaManager.php 87.71% <0%> (ø) 17% <0%> (ø) ⬇️
... and 82 more

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 ab8d8e9...e024d4d. Read the comment docs.

@dpakach dpakach force-pushed the batch-request branch 2 times, most recently from 299635b to 8c9b8f6 Compare June 4, 2019 02:41
@dpakach dpakach changed the title Add batch user creation step for speeding up the requests [wip]Add batch user creation step for speeding up the requests Jun 4, 2019
@dpakach dpakach changed the title [wip]Add batch user creation step for speeding up the requests Add batch user creation step for speeding up the requests Jun 11, 2019
Comment thread tests/acceptance/features/bootstrap/Provisioning.php Outdated
Comment thread tests/TestHelpers/HttpRequestHelper.php Outdated
Comment thread tests/acceptance/features/bootstrap/Provisioning.php
Comment thread tests/acceptance/features/bootstrap/Provisioning.php Outdated
Comment thread tests/acceptance/features/bootstrap/Provisioning.php

@individual-it individual-it left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

please squash before merging

@phil-davis

Copy link
Copy Markdown
Contributor

There are various acceptance test CI fails, so I guess something in this code is not quite right.

$requests,
$client = null
) {
if (!isset($client)) {

@skshetry skshetry Jun 13, 2019

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Only null check should be enough. isset checks if the variable is declared or not in addition to null-check.

Suggested change
if (!isset($client)) {
if ($client === null) {

or,

Suggested change
if (!isset($client)) {
if (is_null($client)) {

Comment thread tests/acceptance/features/bootstrap/Provisioning.php
);
}
// Send all the requests in parallel.
$response = HttpRequestHelper::sendBatchRequest($requests, $client);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This is not really a response. Could get confusing.

Comment thread tests/acceptance/features/bootstrap/Provisioning.php
@dpakach

dpakach commented Jun 13, 2019

Copy link
Copy Markdown
Contributor Author

Backport on #35522

@phil-davis

Copy link
Copy Markdown
Contributor

@dpakach tomorrow please talk with @skshetry about his recent comments. Then if there is good refactoring to do, make another PR for that.

@dpakach

dpakach commented Jun 13, 2019

Copy link
Copy Markdown
Contributor Author

@dpakach tomorrow please talk with @skshetry about his recent comments. Then if there is good refactoring to do, make another PR for that.

@phil-davis I have already started refactoring. It's almost over. I couldnt do PR today because it was late.

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.

6 participants