Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
monitoring
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
cylab
monitoring
Commits
3b4dce86
Commit
3b4dce86
authored
2 months ago
by
Thibault Debatty
Browse files
Options
Downloads
Patches
Plain Diff
use analysis agent class name instead of label in the logs
parent
f97e9093
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#19902
passed
2 months ago
Stage: test
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/Jobs/RunAgent.php
+4
-4
4 additions, 4 deletions
app/Jobs/RunAgent.php
with
4 additions
and
4 deletions
app/Jobs/RunAgent.php
+
4
−
4
View file @
3b4dce86
...
...
@@ -40,7 +40,7 @@ class RunAgent implements ShouldQueue
$this
->
agent
=
$agent
;
$this
->
record
=
$record
;
logger
()
->
info
(
"Dispatch agent "
.
$agent
->
config
()
->
label
.
logger
()
->
info
(
"Dispatch agent "
.
get_class
(
$agent
)
.
" for server #"
.
$record
->
server_id
);
logger
()
->
info
(
"Queue size: "
.
Queue
::
size
());
}
...
...
@@ -52,8 +52,8 @@ class RunAgent implements ShouldQueue
*/
public
function
handle
()
{
$label
=
$this
->
agent
->
config
()
->
label
;
logger
()
->
info
(
"Start agent
$label
for server #"
.
$this
->
record
->
server_id
);
logger
()
->
info
(
"Start agent "
.
get_class
(
$this
->
agent
)
.
"
for server #"
.
$this
->
record
->
server_id
);
$start
=
microtime
(
true
);
$record
=
$this
->
record
;
...
...
@@ -68,6 +68,6 @@ class RunAgent implements ShouldQueue
}
$runtime
=
round
((
microtime
(
true
)
-
$start
)
*
1000
);
logger
()
->
info
(
"End agent
$label
| Execution time:
$runtime
ms"
);
logger
()
->
info
(
"End agent
"
.
get_class
(
$this
->
agent
)
.
"
| Execution time:
$runtime
ms"
);
}
}
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