Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
N
node-bigstream
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bs
node-bigstream
Commits
8bcf2989
Commit
8bcf2989
authored
Mar 01, 2017
by
project
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
--no commit message
--no commit message
parent
c2ab70f8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
index.js
storage-service/ws/v0.1/index.js
+1
-1
service-storage.js
storage-service/ws/v0.1/service-storage.js
+4
-3
No files found.
storage-service/ws/v0.1/index.js
View file @
8bcf2989
...
...
@@ -2,7 +2,7 @@ var express = require('express');
var
router
=
express
.
Router
();
router
.
use
(
'/object'
,
require
(
'./service-object'
));
//
router.use('/storage',require('./service-storage'));
router
.
use
(
'/storage'
,
require
(
'./service-storage'
));
module
.
exports
=
router
;
storage-service/ws/v0.1/service-storage.js
View file @
8bcf2989
...
...
@@ -7,9 +7,10 @@ var fs = require('fs');
var
async
=
require
(
'async'
);
var
cfg
=
ctx
.
config
;
var
storage_cfg
=
cfg
.
storage
;
var
response
=
ctx
.
getlib
(
'lib/ws/response'
);
var
request
=
ctx
.
getlib
(
'lib/ws/request'
);
var
BinStream
=
ctx
.
getlib
(
'lib/storage/binarystream_v1_
0
'
);
var
BinStream
=
ctx
.
getlib
(
'lib/storage/binarystream_v1_
1
'
);
var
ObjId
=
ctx
.
getlib
(
'lib/storage/objid'
);
router
.
get
(
'/:id/stats'
,
function
(
req
,
res
)
{
...
...
@@ -22,7 +23,7 @@ router.get('/:id/stats',function (req, res) {
}
var
storage_path
=
sid
.
split
(
'.'
).
join
(
'/'
);
var
bss_full_path
=
cfg
.
repository
.
path
+
"/"
+
storage_path
+
".bss"
;
var
bss_full_path
=
storage_cfg
.
repository
+
"/"
+
storage_path
+
".bss"
;
fs
.
exists
(
bss_full_path
,
function
(
exists
){
...
...
@@ -59,7 +60,7 @@ router.get('/:id/objects',function (req, res) {
}
var
storage_path
=
sid
.
split
(
'.'
).
join
(
'/'
);
var
bss_full_path
=
cfg
.
repository
.
path
+
"/"
+
storage_path
+
".bss"
;
var
bss_full_path
=
storage_cfg
.
repository
+
"/"
+
storage_path
+
".bss"
;
var
from_seq
=
1
;
var
limit
=
0
;
...
...
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