RealDevSquad / RealDevSquad/website-backend

Refactor User Logs for Timeline Feature and Standardize Log Collection

Open
#2,193 0 comments 0 reactions 1 assignee View on GitHub

@vinit717 is already working on this.

Since Oct 3, 2024.

Dominant language
JavaScript
Stars
74
Forks
276
Avg merge
1d 26m
Merged PRs (30d)
14

Description

Issue Description

To implement a user timeline feature or any logs query functionality, we need to refactor the current user activity logs. The existing log storage is not consistent with the data model and lacks essential fields like metadata, timestamps, and proper key-value structure. The current logging implementation at certain functions is inadequate and needs to be refactored to align with the desired user timeline functionality.

Expected Behavior
  • Logs should follow a consistent data model with appropriate key-value pairs.
  • Each log entry should contain essential fields such as meta, created_at, and a precise timestamp etc.
  • Refactored logs should allow for a seamless generation of user timelines, capturing all relevant user activities.
Current Behavior
  • Logs are not stored in a structured manner and lack uniformity across different parts of the application.
  • Critical fields like meta, created_at, and timestamp are either missing or inconsistent.
  • This makes it challenging to build a reliable user timeline and track activity efficiently.
Screenshots

image
image

Reproducibility
  • This issue is reproducible
  • This issue is not reproducible
Steps to Reproduce
  1. Check existing log storage in functions where user activity is logged.
  2. Note the absence or inconsistency in key fields like meta and created_at, and body.
Severity/Priority
  • Critical
  • High
  • Medium
  • Low
Checklist
  • I have read and followed the project's code of conduct.
  • I have searched for similar issues before creating this one.
  • I have provided all the necessary information to understand and reproduce the issue.
  • I am willing to contribute to the resolution of this issue.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.