Commit 00e022a
Make want batches smaller (#758)
* add simple test
* wip
* ranges work
* fix bugs
* fix tests
* deopt instead of failing wants in bad cases
* and we are done
* format
* Add unit tests for `LocalWants` & `RemoteWants` (#762)
Includes the following:
- `LocalWants`'s `.add()`
- `LocalWants`'s `.remove()`
- `LocalWants`'s `.destroy()`
- `RemoteWants`'s `.add()`
- `RemoteWants`'s `.remove()`
- `RemoteWants`'s `.hasRange()`
* Update lib/replicator.js
Co-authored-by: Sean Zellmer <[email protected]>
* Update lib/replicator.js
Co-authored-by: Sean Zellmer <[email protected]>
* Update lib/replicator.js
Co-authored-by: Sean Zellmer <[email protected]>
* Update lib/wants.js
Co-authored-by: Sean Zellmer <[email protected]>
* Update lib/wants.js
Co-authored-by: Sean Zellmer <[email protected]>
* lint
* Update lib/replicator.js
Co-authored-by: Sean Zellmer <[email protected]>
* fix some issues
* Update lib/replicator.js
Co-authored-by: Sean Zellmer <[email protected]>
---------
Co-authored-by: Sean Zellmer <[email protected]>1 parent cb195fb commit 00e022a
File tree
9 files changed
+966
-114
lines changed- lib
- test
9 files changed
+966
-114
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
420 | 420 | | |
421 | 421 | | |
422 | 422 | | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
423 | 443 | | |
424 | 444 | | |
425 | 445 | | |
| |||
475 | 495 | | |
476 | 496 | | |
477 | 497 | | |
478 | | - | |
| 498 | + | |
479 | 499 | | |
480 | 500 | | |
481 | 501 | | |
482 | 502 | | |
483 | 503 | | |
484 | 504 | | |
485 | | - | |
486 | | - | |
487 | | - | |
| 505 | + | |
| 506 | + | |
488 | 507 | | |
489 | 508 | | |
490 | | - | |
491 | | - | |
| 509 | + | |
| 510 | + | |
492 | 511 | | |
493 | 512 | | |
494 | 513 | | |
| 514 | + | |
495 | 515 | | |
496 | 516 | | |
497 | 517 | | |
| |||
521 | 541 | | |
522 | 542 | | |
523 | 543 | | |
524 | | - | |
525 | | - | |
526 | | - | |
527 | | - | |
528 | | - | |
529 | | - | |
530 | | - | |
531 | | - | |
532 | | - | |
533 | | - | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
543 | 543 | | |
544 | 544 | | |
545 | 545 | | |
| 546 | + | |
| 547 | + | |
546 | 548 | | |
547 | 549 | | |
548 | 550 | | |
549 | 551 | | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
550 | 555 | | |
551 | 556 | | |
552 | 557 | | |
553 | 558 | | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
554 | 562 | | |
555 | 563 | | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
556 | 568 | | |
557 | | - | |
558 | | - | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
559 | 572 | | |
560 | 573 | | |
561 | 574 | | |
| |||
564 | 577 | | |
565 | 578 | | |
566 | 579 | | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
567 | 583 | | |
568 | 584 | | |
569 | 585 | | |
570 | 586 | | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
571 | 590 | | |
572 | 591 | | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
573 | 596 | | |
574 | | - | |
575 | | - | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
576 | 600 | | |
577 | 601 | | |
578 | 602 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
| 150 | + | |
150 | 151 | | |
151 | 152 | | |
152 | 153 | | |
| |||
0 commit comments