mirror of
https://github.com/alexgo-io/redstone-cache-layer.git
synced 2026-04-30 20:52:07 +08:00
feat: logs
This commit is contained in:
1
.github/workflows/deploy-lambda-to-ecr.yml
vendored
1
.github/workflows/deploy-lambda-to-ecr.yml
vendored
@@ -4,6 +4,7 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
- lambda-with-metrics
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
|||||||
@@ -94,6 +94,7 @@ export const packages = (router: Router) => {
|
|||||||
router.get(
|
router.get(
|
||||||
"/packages/latest",
|
"/packages/latest",
|
||||||
asyncHandler(async (req, res) => {
|
asyncHandler(async (req, res) => {
|
||||||
|
console.log("Getting latest packages")
|
||||||
const initialMongoQuery = {};
|
const initialMongoQuery = {};
|
||||||
return await findPackage(req, res, initialMongoQuery);
|
return await findPackage(req, res, initialMongoQuery);
|
||||||
})
|
})
|
||||||
@@ -109,7 +110,7 @@ export const packages = (router: Router) => {
|
|||||||
if (!req.query.toTimestamp) {
|
if (!req.query.toTimestamp) {
|
||||||
throw new Error("toTimestamp query param is required");
|
throw new Error("toTimestamp query param is required");
|
||||||
}
|
}
|
||||||
|
console.log("Getting packages by timestamp")
|
||||||
const initialMongoQuery = {
|
const initialMongoQuery = {
|
||||||
timestamp: { $lte: req.query.toTimestamp },
|
timestamp: { $lte: req.query.toTimestamp },
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -276,6 +276,7 @@ export const prices = (router: Router) => {
|
|||||||
eventProps: params,
|
eventProps: params,
|
||||||
ip: getIp(req),
|
ip: getIp(req),
|
||||||
});
|
});
|
||||||
|
console.log("Getting prices")
|
||||||
|
|
||||||
// Getting provider details
|
// Getting provider details
|
||||||
const providerDetails = await getProviderFromParams(params);
|
const providerDetails = await getProviderFromParams(params);
|
||||||
|
|||||||
Reference in New Issue
Block a user