Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
strudel2_backend
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
Container Registry
Model registry
Operate
Environments
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hpc-team
strudel2_backend
Commits
e3f9c5f8
Commit
e3f9c5f8
authored
2 years ago
by
Chris Hines
Browse files
Options
Downloads
Patches
Plain Diff
fix up logging, increase idel websockets out to 5 minutes
parent
ecdf690a
No related branches found
Branches containing commit
No related tags found
2 merge requests
!90
I think there is a problem with multiple threads creating multiple sessions...
,
!88
Dev
Pipeline
#56734
passed
2 years ago
Stage: build
Stage: deploy
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
nginx_snippets/tws.conf
+3
-0
3 additions, 0 deletions
nginx_snippets/tws.conf
twsproxy/__init__.py
+1
-3
1 addition, 3 deletions
twsproxy/__init__.py
with
4 additions
and
3 deletions
nginx_snippets/tws.conf
+
3
−
0
View file @
e3f9c5f8
...
...
@@ -5,6 +5,9 @@ location / {
proxy_http_version
1
.
1
;
proxy_set_header
Upgrade
$
http_upgrade
;
proxy_set_header
Connection
$
connection_upgrade
;
proxy_read_timeout
300
;
proxy_connect_timeout
300
;
proxy_send_timeout
300
;
add_header
'Access-Control-Allow-Origin'
$
http_origin
;
add_header
'Access-Control-Allow-Credentials'
'true'
;
client_max_body_size
50
M
;
...
...
This diff is collapsed.
Click to expand it.
twsproxy/__init__.py
+
1
−
3
View file @
e3f9c5f8
...
...
@@ -171,8 +171,6 @@ class TWSProxy(threading.Thread):
if
msglength
>
0
:
TWSProxy
.
reliablesend
(
dest
,
buff
,
msglength
)
if
msglength
==
0
:
logger
.
debug
(
'
socket shutdown, fh ready to read but 0 bytes returned
'
)
logger
.
debug
(
'
{} {}
'
.
format
(
r
,
src
))
#dest.send(buff)
dest
.
shutdown
(
shuttype
)
initshutdown
.
set
()
...
...
@@ -192,7 +190,7 @@ def mainserver(port=None):
logger
=
logging
.
getLogger
()
handler
=
TimedRotatingFileHandler
(
filename
=
"
/var/log/strudel2/tws.log
"
,
when
=
'
h
'
,
interval
=
24
,
backupCount
=
7
)
formatter
=
logging
.
Formatter
(
"
%(asctime)s %(levelname)s:%(process)s: %(message)s
"
)
handler
.
setFormatt
t
er
(
formatter
)
handler
.
setFormatter
(
formatter
)
logger
.
addHandler
(
handler
)
except
Exception
as
e
:
import
traceback
...
...
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