Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
Warden
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pavel Valach
Warden
Commits
f86bec60
Commit
f86bec60
authored
10 years ago
by
Tomáš Plesník
Browse files
Options
Downloads
Patches
Plain Diff
uprava chybove hlasky pri deserializaci odpovedi serveru
parent
9bf5146b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/warden-client/lib/WardenClientCommon.pm
+6
-6
6 additions, 6 deletions
src/warden-client/lib/WardenClientCommon.pm
with
6 additions
and
6 deletions
src/warden-client/lib/WardenClientCommon.pm
+
6
−
6
View file @
f86bec60
...
...
@@ -25,9 +25,9 @@ our $VERSION = "2.2";
sub
errMsg
{
my
$msg
=
shift
;
my
$type
=
shift
;
my
$type
=
shift
;
defined
$type
or
$type
=
"
err
";
# default type is err. Other: warn
# check verbose logging
if
((
$type
eq
"
err
")
&&
(
$
WardenClientCommon::
LOG_VERBOSE
))
{
$msg
.=
"
\n
Stack info:
"
.
Carp::
longmess
();
...
...
@@ -69,7 +69,7 @@ sub c2s
eval
{
$client
=
SOAP::Transport::HTTP::
Client
->
new
();
}
or
return
errMsg
("
Error in function 'c2s()' when creating SOAP::Transport::HTTP::Client object:
"
.
$@
);
# setting of connection timeout
eval
{
$client
->
timeout
(
$
WardenClientCommon::
CONNECTION_TIMEOUT
);}
or
return
errMsg
("
Error in function 'c2s()' when setting connection timeout:
"
.
$@
);
...
...
@@ -90,7 +90,7 @@ sub c2s
eval
{
$soap
=
SOAP::
Lite
->
uri
(
$service
)
->
proxy
(
$
WardenClientCommon::
URI
);
}
or
return
errMsg
("
Error in function 'c2s()' when setting service URI:
"
.
$@
);
# serialize SOAP envelope or SOAP envelope and data object
my
$envelope
;
if
(
!
defined
$data
)
{
...
...
@@ -118,9 +118,9 @@ sub c2s
my
$response
;
eval
{
$response
=
$soap
->
deserializer
->
deserialize
(
$result
);
}
or
return
errMsg
("
Error in deserialization of server response:
"
.
$@
.
"
(
Received response:
"
.
$result
.
"
)
"
);
}
or
return
errMsg
("
Error in deserialization of server response:
"
.
$@
.
"
\n
Received response:
"
.
$result
);
# check SOAP fault status
$response
->
fault
?
return
errMsg
("
Server sent error message:
:
"
.
$response
->
faultstring
)
:
return
$response
;
$response
->
fault
?
return
errMsg
("
Server sent error message:
"
.
$response
->
faultstring
)
:
return
$response
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment