File tree Expand file tree Collapse file tree 2 files changed +26
-10
lines changed Expand file tree Collapse file tree 2 files changed +26
-10
lines changed Original file line number Diff line number Diff line change @@ -170,11 +170,17 @@ class NamespaceBlob {
170
170
} catch ( err ) {
171
171
this . _translate_error_code ( err ) ;
172
172
dbg . warn ( 'NamespaceBlob.read_object_md:' , inspect ( err ) ) ;
173
- object_sdk . rpc_client . pool . update_issues_report ( {
174
- namespace_resource_id : this . namespace_resource_id ,
175
- error_code : err . code || ( err . details && err . details . errorCode ) || 'InternalError' ,
176
- time : Date . now ( ) ,
177
- } ) ;
173
+
174
+ // It's totally expected to issue `HeadObject` against an object that doesn't exist
175
+ // this shouldn't be counted as an issue for the namespace store
176
+ if ( err . rpc_code !== 'NO_SUCH_OBJECT' ) {
177
+ object_sdk . rpc_client . pool . update_issues_report ( {
178
+ namespace_resource_id : this . namespace_resource_id ,
179
+ error_code : err . code || ( err . details && err . details . errorCode ) || 'InternalError' ,
180
+ time : Date . now ( ) ,
181
+ } ) ;
182
+ }
183
+
178
184
throw err ;
179
185
}
180
186
}
Original file line number Diff line number Diff line change @@ -217,11 +217,21 @@ class NamespaceS3 {
217
217
} catch ( err ) {
218
218
this . _translate_error_code ( params , err ) ;
219
219
dbg . warn ( 'NamespaceS3.read_object_md:' , inspect ( err ) ) ;
220
- object_sdk . rpc_client . pool . update_issues_report ( {
221
- namespace_resource_id : this . namespace_resource_id ,
222
- error_code : String ( err . code ) ,
223
- time : Date . now ( ) ,
224
- } ) ;
220
+
221
+ // It's totally expected to issue `HeadObject` against an object that doesn't exist
222
+ // this shouldn't be counted as an issue for the namespace store
223
+ //
224
+ // @TODO : Another error to tolerate is 'InvalidObjectState'. This shouldn't also
225
+ // result in IO_ERROR for the namespace however that means we can not do `getObject`
226
+ // even when `can_use_get_inline` is true.
227
+ if ( err . rpc_code !== 'NO_SUCH_OBJECT' ) {
228
+ object_sdk . rpc_client . pool . update_issues_report ( {
229
+ namespace_resource_id : this . namespace_resource_id ,
230
+ error_code : String ( err . code ) ,
231
+ time : Date . now ( ) ,
232
+ } ) ;
233
+ }
234
+
225
235
throw err ;
226
236
}
227
237
}
You can’t perform that action at this time.
0 commit comments