Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
noc
noc
Commits
061196b7
Commit
061196b7
authored
May 14, 2020
by
Andrey Vertiprahov
Browse files
Catch portmapper exception on NRI discovery.
parent
bd30a950
Pipeline
#23071
passed with stages
in 19 minutes and 25 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
services/discovery/jobs/box/nri_portmap.py
View file @
061196b7
...
...
@@ -55,7 +55,13 @@ class NRIPortmapperCheck(DiscoveryCheck):
{
"managed_object"
:
self
.
object
.
id
,
"type"
:
"physical"
},
{
"_id"
:
1
,
"name"
:
1
,
"nri_name"
:
1
},
):
nri_name
=
portmapper
.
to_remote
(
d
[
"name"
],
iface_hints
=
ifaces_hints
)
try
:
nri_name
=
portmapper
.
to_remote
(
d
[
"name"
],
iface_hints
=
ifaces_hints
)
except
Exception
as
e
:
self
.
logger
.
error
(
"[%s] Unhandled exception on portmapper handler '%s'. Skipping checks."
,
nri
,
e
)
break
self
.
logger
.
debug
(
"[%s] Port mapping %s <-> %s"
,
nri
,
d
[
"name"
],
nri_name
)
if
not
nri_name
:
self
.
logger
.
info
(
"[%s] Cannot map port name '%s'"
,
nri
,
d
[
"name"
])
...
...
Dmitry Volodin
@dv
mentioned in commit
aca7787e
·
May 17, 2020
mentioned in commit
aca7787e
mentioned in commit aca7787e61c960ab91629c4c2cdaf54b4c2384b5
Toggle commit list
Andrey Vertiprahov
@aversant
mentioned in merge request
!3621 (merged)
·
May 17, 2020
mentioned in merge request
!3621 (merged)
mentioned in merge request !3621
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment