Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
apachedex
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
apachedex
Commits
580a24eb
Commit
580a24eb
authored
Apr 03, 2013
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Drop stale support for missing duration.
parent
72dab44a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
13 deletions
+11
-13
apachedex/__init__.py
apachedex/__init__.py
+11
-13
No files found.
apachedex/__init__.py
View file @
580a24eb
...
@@ -133,20 +133,18 @@ class GenericSiteStats(object):
...
@@ -133,20 +133,18 @@ class GenericSiteStats(object):
def
accumulate
(
self
,
match
,
url_match
,
date
):
def
accumulate
(
self
,
match
,
url_match
,
date
):
self
.
status
[
match
.
group
(
'status'
)][
date
]
+=
1
self
.
status
[
match
.
group
(
'status'
)][
date
]
+=
1
duration
=
match
.
group
(
'duration'
)
self
.
apdex
[
date
].
accumulate
(
match
)
self
.
apdex
[
date
].
accumulate
(
match
)
if
duration
is
not
None
:
duration
=
int
(
match
.
group
(
'duration'
))
duration
=
int
(
duration
)
if
url_match
is
None
:
if
url_match
is
None
:
url
=
match
.
group
(
'request'
)
url
=
match
.
group
(
'request'
)
else
:
else
:
url
=
url_match
.
group
(
'url'
)
url
=
url_match
.
group
(
'url'
)
if
duration
>
self
.
slowest_list
[
0
][
0
]:
if
duration
>
self
.
slowest_list
[
0
][
0
]:
slowest_list
=
self
.
slowest_list
slowest_list
=
self
.
slowest_list
slowest_list
.
append
((
duration
,
match
.
group
(
'timestamp'
),
url
,
slowest_list
.
append
((
duration
,
match
.
group
(
'timestamp'
),
url
,
match
.
group
(
'referer'
)))
match
.
group
(
'referer'
)))
if
len
(
slowest_list
)
>
N_SLOWEST_THRESHOLD
:
if
len
(
slowest_list
)
>
N_SLOWEST_THRESHOLD
:
self
.
_housekeeping
()
self
.
_housekeeping
()
def
_housekeeping
(
self
):
def
_housekeeping
(
self
):
slowest_list
=
self
.
slowest_list
slowest_list
=
self
.
slowest_list
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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