Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
nexus_semantic_logger
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
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
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Public
nexus_semantic_logger
Commits
d313f799
Commit
d313f799
authored
4 months ago
by
Theo Cushion
Browse files
Options
Downloads
Patches
Plain Diff
chore: remove references to NexusSemanticLogger::ResponseCodeStatsMiddleware
parent
e27be54b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!13
chore: remove references to NexusSemanticLogger::ResponseCodeStatsMiddleware
Pipeline
#90362
passed
4 months ago
Stage: test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+0
-8
0 additions, 8 deletions
README.md
lib/puma/plugin/nexus_puma_statsd.rb
+0
-8
0 additions, 8 deletions
lib/puma/plugin/nexus_puma_statsd.rb
with
0 additions
and
16 deletions
README.md
+
0
−
8
View file @
d313f799
...
...
@@ -10,7 +10,6 @@ As well as providing a semantic logger, this gem handles datadog telemetry assoc
*
traces
*
metrics
*
statsd is automatically attached to datadog runtime metrics and may also be used for custom metrics.
*
`ResponseCodeStatsMiddleware`
is included to capture response code metrics from rack applications
### Customise log level per logger
...
...
@@ -61,13 +60,6 @@ For example, to increment a count:
NexusSemanticLogger.metrics.increment('nexus.users.registration.complete')
```
### Rack response code metrics
This can be configured with a middleware in application.rb
```
config.middleware.use ResponseCodeStatsMiddleware
```
# Local gem development
Steps to run this gem from local sources in one the nexus 'staged build' rails components:
...
...
This diff is collapsed.
Click to expand it.
lib/puma/plugin/nexus_puma_statsd.rb
+
0
−
8
View file @
d313f799
...
...
@@ -164,14 +164,6 @@ Puma::Plugin.create do
NexusSemanticLogger
.
metrics
.
gauge
(
'puma.pool_capacity'
,
stats
.
pool_capacity
,
tags:
tags
)
NexusSemanticLogger
.
metrics
.
gauge
(
'puma.max_threads'
,
stats
.
max_threads
,
tags:
tags
)
NexusSemanticLogger
.
metrics
.
count
(
'puma.requests_count'
,
stats
.
requests_count
,
tags:
tags
)
NexusSemanticLogger
::
ResponseCodeStatsMiddleware
.
read_and_reset_metrics
.
each
do
|
code
,
count
|
NexusSemanticLogger
.
metrics
.
count
(
"puma.rack.response.status"
,
count
,
tags:
tags
+
[
"response_status:
#{
code
}
"
]
)
end
rescue
StandardError
=>
e
@log_writer
.
unknown_error
(
e
,
nil
,
'! statsd: notify stats failed'
)
ensure
...
...
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