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 @@ -161,11 +161,17 @@ class NamespaceBlob {
161
161
} catch ( err ) {
162
162
this . _translate_error_code ( err ) ;
163
163
dbg . warn ( 'NamespaceBlob.read_object_md:' , inspect ( err ) ) ;
164
- object_sdk . rpc_client . pool . update_issues_report ( {
165
- namespace_resource_id : this . namespace_resource_id ,
166
- error_code : err . code || ( err . details && err . details . errorCode ) || 'InternalError' ,
167
- time : Date . now ( ) ,
168
- } ) ;
164
+
165
+ // It's totally expected to issue `HeadObject` against an object that doesn't exist
166
+ // this shouldn't be counted as an issue for the namespace store
167
+ if ( err . rpc_code !== 'NO_SUCH_OBJECT' ) {
168
+ object_sdk . rpc_client . pool . update_issues_report ( {
169
+ namespace_resource_id : this . namespace_resource_id ,
170
+ error_code : err . code || ( err . details && err . details . errorCode ) || 'InternalError' ,
171
+ time : Date . now ( ) ,
172
+ } ) ;
173
+ }
174
+
169
175
throw err ;
170
176
}
171
177
}
Original file line number Diff line number Diff line change @@ -207,11 +207,21 @@ class NamespaceS3 {
207
207
} catch ( err ) {
208
208
this . _translate_error_code ( params , err ) ;
209
209
dbg . warn ( 'NamespaceS3.read_object_md:' , inspect ( err ) ) ;
210
- object_sdk . rpc_client . pool . update_issues_report ( {
211
- namespace_resource_id : this . namespace_resource_id ,
212
- error_code : String ( err . code ) ,
213
- time : Date . now ( ) ,
214
- } ) ;
210
+
211
+ // It's totally expected to issue `HeadObject` against an object that doesn't exist
212
+ // this shouldn't be counted as an issue for the namespace store
213
+ //
214
+ // @TODO : Another error to tolerate is 'InvalidObjectState'. This shouldn't also
215
+ // result in IO_ERROR for the namespace however that means we can not do `getObject`
216
+ // even when `can_use_get_inline` is true.
217
+ if ( err . rpc_code !== 'NO_SUCH_OBJECT' ) {
218
+ object_sdk . rpc_client . pool . update_issues_report ( {
219
+ namespace_resource_id : this . namespace_resource_id ,
220
+ error_code : String ( err . code ) ,
221
+ time : Date . now ( ) ,
222
+ } ) ;
223
+ }
224
+
215
225
throw err ;
216
226
}
217
227
}
You can’t perform that action at this time.
0 commit comments