Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
A
augustctl
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Code Review
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
open-source
augustctl
Commits
ddb50090
Verified
Commit
ddb50090
authored
Aug 28, 2016
by
Erick Hitter
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Lower cache lives
parent
aa8e3e7f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
server.js
server.js
+2
-2
No files found.
server.js
View file @
ddb50090
...
...
@@ -83,7 +83,7 @@ function disconnectAndClear( lockName ) {
*/
// Endpoint to check lock status
app
.
get
(
'
/api/status/:lock_name
'
,
cache
(
'
1
5 seconds
'
),
function
(
req
,
res
)
{
app
.
get
(
'
/api/status/:lock_name
'
,
cache
(
'
5 seconds
'
),
function
(
req
,
res
)
{
// Parse allowed request arguments
var
lock
=
getLockInstance
(
req
.
params
.
lock_name
);
if
(
!
lock
)
{
...
...
@@ -111,7 +111,7 @@ app.get( '/api/status/:lock_name', cache( '15 seconds' ), function( req, res ) {
}
);
// Endpoint to change lock state
app
.
get
(
'
/api/:lock_action(lock|unlock)/:lock_name
'
,
cache
(
'
5
seconds
'
),
function
(
req
,
res
)
{
app
.
get
(
'
/api/:lock_action(lock|unlock)/:lock_name
'
,
cache
(
'
3
seconds
'
),
function
(
req
,
res
)
{
// Parse allowed request arguments
var
action
=
req
.
params
.
lock_action
,
allowedActions
=
[
'
unlock
'
,
'
lock
'
];
...
...
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