{"id":20463110,"url":"https://github.com/shubhamharitash/logginglibrary-slf4j","last_synced_at":"2026-05-27T20:32:02.482Z","repository":{"id":242371228,"uuid":"809383524","full_name":"shubhamharitash/LoggingLibrary-SLF4J","owner":"shubhamharitash","description":"LoggingLibrary - SLF4J Asked in Flipkart Machine Coding Round","archived":false,"fork":false,"pushed_at":"2024-06-23T17:27:33.000Z","size":13,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-24T03:27:41.575Z","etag":null,"topics":["commandlineapplication","flipkart","flipkart-health-plus","flipkart-machine-coding-round","flipkartsde2","flipkartsde3","java-developer","lld","machinecoding","sde2","sde3","supermoney","system-design","walmart"],"latest_commit_sha":null,"homepage":"https://youtu.be/zuJsBoGPhJ4","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shubhamharitash.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-02T14:39:38.000Z","updated_at":"2024-11-03T17:15:01.000Z","dependencies_parsed_at":"2024-06-02T16:09:49.492Z","dependency_job_id":"115d4e67-f304-41a8-8de2-ab1205c074ee","html_url":"https://github.com/shubhamharitash/LoggingLibrary-SLF4J","commit_stats":null,"previous_names":["shubhamharitash/logginglibrary-slf4j"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/shubhamharitash/LoggingLibrary-SLF4J","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shubhamharitash%2FLoggingLibrary-SLF4J","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shubhamharitash%2FLoggingLibrary-SLF4J/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shubhamharitash%2FLoggingLibrary-SLF4J/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shubhamharitash%2FLoggingLibrary-SLF4J/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shubhamharitash","download_url":"https://codeload.github.com/shubhamharitash/LoggingLibrary-SLF4J/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shubhamharitash%2FLoggingLibrary-SLF4J/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33583394,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-27T02:00:06.184Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["commandlineapplication","flipkart","flipkart-health-plus","flipkart-machine-coding-round","flipkartsde2","flipkartsde3","java-developer","lld","machinecoding","sde2","sde3","supermoney","system-design","walmart"],"created_at":"2024-11-15T13:09:21.368Z","updated_at":"2026-05-27T20:32:02.458Z","avatar_url":"https://github.com/shubhamharitash.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"Simple Logging Library\n\nVideo Explanation  : https://youtu.be/zuJsBoGPhJ4\n\nObjective:\n\nDevelop a basic logging library that can be used by applications to log\nmessages. The library should handle message logging efficiently and reliably, offering\nbasic configuration options.\n\nKey Requirements:\n\n● Driver Application should be able to Initialize the Library and log messages to the\ndesired sink.\n● Logger has the following capabilities-\n○ Accepts messages from client(s)\n○ A logger would have one or more sinks associated with it.\n○ Supports defined message levels.\n○ enriches message with current timestamp while directing message to a sink\n○ Logger is initialized with a configuration eg:logger name, sink(s), buffer size.\n○ Logger should support both sync and async logging.\n■ For Async logger buffer size would determine the maximum inflight\nmessages.\n○ Messages must be ordered. Messages should reach the sink in the order they\nwere sent.\n○ Should support writes from multiple-threads.\n○ There shouldn’t be any data loss.\n● Sink:\n○ There can be various types of sink (file, stdout, database).\n○ Sink has a destination.\n■ For this round you may create STDOUT sink, which would print the\nmessage to the console.\n○ Sink has an associated log level. Any message with the level lower than the\nsink level should be discarded.\n● Message\n○ has content which is of type string\n○ has a level associated with it\n● Log Level\n○ DEBUG, INFO, WARN, ERROR, FATAL ; in order of priority. ERROR has higher\npriority than INFO.\n\nSending messages\n\n● Sink need not be mentioned while sending a message to the logger library.\n● You specify message content and level while sending a message\n\nLogger configuration (see sample below)\n\n● Specifies all the details required to use the logger library.\n● Library can accept one or more configuration for an application\n● Example:\n○ time format\n○ logging level\n○ sink type\n○ Logger type sync/async\n○ details required for sink (eg file location)); this depends on sink type.\n\nSample Config:\n\nTs_format: any format\nlog_level:INFO\nlogger_type:ASYNC\nbuffer_size:25\nsink_type:STDOUT\n\nSample Output Log Entry\n\n03-01-2024-09-30-00 [INFO] This is a sample log message.\n\nExpectations and Guidelines\n\n1. Create the sample data yourself. You can put it into a file, test case or main driver\nprogram itself.\n2. The code should be demo-able. Either by using the main driver program or test cases.\n3. The code should be modular. The code should have the basic OO design. Please do not\njam in the responsibilities of one class into another.\n4. The code should be extensible. Wherever applicable, use interfaces and contracts\nbetween different methods. It should be easy to add/remove functionality without\nrewriting the entire codebase.\n5. The code should handle edge cases properly and fail gracefully.\n6. The code should be legible, readable and DRY.\n7. Database integration is not required.\n8. Please do not access the internet for anything EXCEPT syntax.\n9. You are free to use the language and IDE of your choice.\n10. The entire code should be your own.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshubhamharitash%2Flogginglibrary-slf4j","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshubhamharitash%2Flogginglibrary-slf4j","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshubhamharitash%2Flogginglibrary-slf4j/lists"}