Skip to content

Commit

Permalink
fix: remove meta logs
Browse files Browse the repository at this point in the history
  • Loading branch information
The-Sebastian committed Jan 30, 2025
1 parent 0f9ea0e commit 60c54c7
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 17 deletions.
5 changes: 0 additions & 5 deletions lib/aws/dynamodb-document.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ export class DynamodbDocumentClient {
async get(key, params = {}) {
const log = this._log.child({
...this._getHashAndRangeKeyObj(key),
meta: { key, params },
method: 'get'
})
try {
Expand All @@ -72,7 +71,6 @@ export class DynamodbDocumentClient {
async put(item, params = {}) {
const log = this._log.child({
...this._getHashAndRangeKeyObj(item),
meta: { params },
method: 'put'
})
try {
Expand All @@ -96,7 +94,6 @@ export class DynamodbDocumentClient {

async delete(key, params = {}) {
const log = this._log.child({
meta: { key, params },
method: 'delete'
})
try {
Expand All @@ -119,7 +116,6 @@ export class DynamodbDocumentClient {

async query(params) {
const log = this._log.child({
meta: { params },
method: 'query'
})
try {
Expand All @@ -142,7 +138,6 @@ export class DynamodbDocumentClient {
async update(key, params = {}) {
const log = this._log.child({
...this._getHashAndRangeKeyObj(key),
meta: { key, params },
method: 'update'
})
try {
Expand Down
1 change: 0 additions & 1 deletion lib/aws/eventbridge.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ export class EventbridgeClient {
*/
async putEvents(events = [], params = {}) {
const log = this._log.child({
meta: { params },
method: 'putEvents'
})
try {
Expand Down
1 change: 0 additions & 1 deletion lib/aws/lambda.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ export class LambdaClient {
*/
async invokeJson(payload, params = {}) {
const log = this._log.child({
meta: { payload, params },
method: 'invokeJson'
})
try {
Expand Down
6 changes: 0 additions & 6 deletions lib/aws/s3.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ export class S3Client {
*/
async upload(key, body, params = {}) {
const log = this._log.child({
meta: { key, params },
method: 'upload'
})
try {
Expand Down Expand Up @@ -80,7 +79,6 @@ export class S3Client {
*/
async uploadJson(key, body, params = {}) {
const log = this._log.child({
meta: { key, params },
method: 'uploadJson'
})
try {
Expand All @@ -107,7 +105,6 @@ export class S3Client {
*/
async getObject(key, params = {}) {
const log = this._log.child({
meta: { key, params },
method: 'getObject'
})
try {
Expand Down Expand Up @@ -139,7 +136,6 @@ export class S3Client {
*/
async getObjectJson(key, params = {}) {
const log = this._log.child({
meta: { key, params },
method: 'getObjectJson'
})
try {
Expand All @@ -164,7 +160,6 @@ export class S3Client {
*/
async listObjectVersions(params = {}) {
const log = this._log.child({
meta: { params },
method: 'listObjectVersions'
})
try {
Expand All @@ -188,7 +183,6 @@ export class S3Client {
*/
async deleteObjects(params = {}) {
const log = this._log.child({
meta: { params },
method: 'deleteObjects'
})
try {
Expand Down
1 change: 0 additions & 1 deletion lib/aws/sns.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ export class SnsClient {
*/
async publishJson(body, params = {}) {
const log = this._log.child({
meta: { body, params },
method: 'publishJson'
})
try {
Expand Down
1 change: 0 additions & 1 deletion lib/aws/sqs.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ export class SqsClient {
*/
async publishJson(body, params = {}) {
const log = this._log.child({
meta: { body, params },
method: 'publishJson'
})
try {
Expand Down
2 changes: 1 addition & 1 deletion lib/wrapper/default-wrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const createDefaultWrapper = (
parser = (event) => event,
serializer = (data) => data
) => (processor) => async (event, context) => {
const log = ctx.log.child({ meta: event, jackalambdaWrapper: 'default' })
const log = ctx.log.child({ jackalambdaWrapper: 'default' })
try {
log.info('handle: start')
const parsedEvent = parser(event, context)
Expand Down
2 changes: 1 addition & 1 deletion lib/wrapper/json-wrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const createApiJsonWrapper = (
parser = (event) => event,
serializer = multiStatusCodeJsonSerializer
) => (processor) => async (event, context) => {
const log = ctx.log.child({ meta: event, jackalambdaWrapper: 'api-json' })
const log = ctx.log.child({ jackalambdaWrapper: 'api-json' })
try {
log.info('handle: start')
const parsedEvent = parser(event, context)
Expand Down

0 comments on commit 60c54c7

Please sign in to comment.