@@ -225,6 +225,7 @@ const kOnFileOpened = Symbol('kOnFileOpened');
225
225
const kOnFileUnpipe = Symbol ( 'kOnFileUnpipe' ) ;
226
226
const kOnPipedFileHandleRead = Symbol ( 'kOnPipedFileHandleRead' ) ;
227
227
const kReady = Symbol ( 'kReady' ) ;
228
+ const kRemoveFromSocket = Symbol ( 'kRemoveFromSocket' ) ;
228
229
const kRemoveSession = Symbol ( 'kRemove' ) ;
229
230
const kRemoveStream = Symbol ( 'kRemoveStream' ) ;
230
231
const kServerBusy = Symbol ( 'kServerBusy' ) ;
@@ -2247,9 +2248,7 @@ class QuicSession extends EventEmitter {
2247
2248
return this [ kInternalState ] . handshakeContinuationHistogram ;
2248
2249
}
2249
2250
2250
- // TODO(addaleax): This is a temporary solution for testing and should be
2251
- // removed later.
2252
- removeFromSocket ( ) {
2251
+ [ kRemoveFromSocket ] ( ) {
2253
2252
return this [ kHandle ] . removeFromSocket ( ) ;
2254
2253
}
2255
2254
}
@@ -2695,7 +2694,17 @@ class QuicStream extends Duplex {
2695
2694
}
2696
2695
2697
2696
[ kAfterAsyncWrite ] ( { bytes } ) {
2698
- // TODO(@jasnell): Implement this
2697
+ // There's currently nothing we need to do here. We have
2698
+ // to have this but it's a non-op
2699
+ }
2700
+
2701
+ [ kUpdateTimer ] ( ) {
2702
+ // Timeout is implemented in the QuicSession at the native
2703
+ // layer. We have to have this here but it's a non-op
2704
+ }
2705
+
2706
+ [ kTrackWriteState ] ( stream , bytes ) {
2707
+ // There's currently nothing to do here.
2699
2708
}
2700
2709
2701
2710
[ kInspect ] ( depth , options ) {
@@ -2712,17 +2721,6 @@ class QuicStream extends Duplex {
2712
2721
} , depth , options ) ;
2713
2722
}
2714
2723
2715
- [ kTrackWriteState ] ( stream , bytes ) {
2716
- // TODO(@jasnell): Not yet sure what we want to do with these
2717
- // this.#writeQueueSize += bytes;
2718
- // this.#writeQueueSize += bytes;
2719
- // this[kHandle].chunksSentSinceLastWrite = 0;
2720
- }
2721
-
2722
- [ kUpdateTimer ] ( ) {
2723
- // TODO(@jasnell): Implement this later
2724
- }
2725
-
2726
2724
get detached ( ) {
2727
2725
// The QuicStream is detached if it is yet destroyed
2728
2726
// but the underlying handle is undefined. While in
@@ -2750,7 +2748,7 @@ class QuicStream extends Duplex {
2750
2748
2751
2749
[ kWriteGeneric ] ( writev , data , encoding , cb ) {
2752
2750
if ( this . destroyed || this . detached )
2753
- return ; // TODO(addaleax): Can this happen?
2751
+ return ;
2754
2752
2755
2753
this [ kUpdateTimer ] ( ) ;
2756
2754
const req = ( writev ) ?
@@ -2810,7 +2808,7 @@ class QuicStream extends Duplex {
2810
2808
}
2811
2809
2812
2810
_read ( nread ) {
2813
- if ( this . destroyed ) { // TODO(addaleax): Can this happen?
2811
+ if ( this . destroyed ) {
2814
2812
this . push ( null ) ;
2815
2813
return ;
2816
2814
}
@@ -2910,11 +2908,6 @@ class QuicStream extends Duplex {
2910
2908
undefined ;
2911
2909
}
2912
2910
2913
- get bufferSize ( ) {
2914
- // TODO(@jasnell): Implement this
2915
- return undefined ;
2916
- }
2917
-
2918
2911
get id ( ) {
2919
2912
return this [ kInternalState ] . id ;
2920
2913
}
@@ -2923,10 +2916,6 @@ class QuicStream extends Duplex {
2923
2916
return this [ kInternalState ] . push_id ;
2924
2917
}
2925
2918
2926
- _onTimeout ( ) {
2927
- // TODO(@jasnell): Implement this
2928
- }
2929
-
2930
2919
get session ( ) {
2931
2920
return this [ kInternalState ] . session ;
2932
2921
}
@@ -3127,7 +3116,8 @@ function createSocket(options) {
3127
3116
3128
3117
module . exports = {
3129
3118
createSocket,
3130
- kUDPHandleForTesting
3119
+ kUDPHandleForTesting,
3120
+ kRemoveFromSocket,
3131
3121
} ;
3132
3122
3133
3123
/* eslint-enable no-use-before-define */
0 commit comments