[{"data":1,"prerenderedAt":803},["ShallowReactive",2],{"blog-sessions-in-golang":3,"blog-all-for-related":347},{"id":4,"title":5,"author":6,"body":7,"cardAlt":5,"categories":330,"description":334,"draft":335,"extension":336,"headerImage":337,"keywords":338,"meta":339,"name":340,"navigation":341,"path":342,"seo":343,"series":6,"stem":344,"updated":6,"year":345,"__hash__":346},"blog\u002Fblog\u002Fsessions-in-golang.md","Sessions using Golang and Redis",null,{"type":8,"value":9,"toc":321},"minimark",[10,14,17,20,317],[11,12,13],"p",{},"In most of the applications\u002FMVP you generally start the implementation with a login\u002Fsignup feature. With some DB interactions this is quite easy.",[11,15,16],{},"But, you don’t want to make user login again and again whenever he opens a new page on your site. You must have noticed on sites like Facebook, Gmail, Twitter — you don’t have to do a login again, rather you are somehow authenticated and you can see the desired home page.",[11,18,19],{},"This automatic authentication which persists all over the site is done with the help of cookies and sessions. Let’s understand them one by one.",[21,22,23,26,31,34,37,55,57,61,64,67,81,83,87,90,97,99,103,119,125,143,146,206,213,218,224,227,248,257,259,263,286,289,298,300,303,312],"ads",{},[24,25],"hr",{},[27,28,30],"h2",{"id":29},"what-are-cookies","What are cookies?",[11,32,33],{},"Cookies are text files stored on the client machine(eg. web browser) which are useful for tracking purpose. It basically stores some information (which can be key value pair). These values are used by server to perform some actions. It allows developers to easily perform long-term user recognition.",[11,35,36],{},"Some useful links on cookies —",[38,39,40,49],"ol",{},[41,42,43],"li",{},[44,45,46],"a",{"href":46,"rel":47},"https:\u002F\u002Fdeveloper.mozilla.org\u002Fen-US\u002Fdocs\u002FWeb\u002FHTTP\u002FCookies",[48],"nofollow",[41,50,51],{},[44,52,53],{"href":53,"rel":54},"https:\u002F\u002Fmedium.com\u002F@endan\u002Fworking-with-http-cookies-d72f1695a913",[48],[24,56],{},[27,58,60],{"id":59},"what-are-sessions","What are sessions?",[11,62,63],{},"A session can be defined as a server-side storage of information that is desired to persist throughout the user’s interaction with the web site or web application.You can pass info via url parameters too, but mostly you don’t want to expose some fields on client side.",[11,65,66],{},"Some useful links on sessions —",[38,68,69,75],{},[41,70,71],{},[44,72,73],{"href":73,"rel":74},"https:\u002F\u002Fstackoverflow.com\u002Fquestions\u002F3804209\u002Fwhat-are-sessions-how-do-they-work",[48],[41,76,77],{},[44,78,80],{"href":79},"%5Bhttps:\u002F\u002Fwww.bitspedia.com\u002F2012\u002F05\u002Fhow-session-works-in-web-applications.html%5D(https:\u002F\u002Fwww.bitspedia.com\u002F2012\u002F05\u002Fhow-session-works-in-web-applications.html)","Detailed explanation on sessions",[24,82],{},[27,84,86],{"id":85},"theory","Theory",[11,88,89],{},"Now, you got the basic idea about cookies and sessions. Let’s now ponder over how we should implement this. Essentially you want to save some cookie on client side, whose value acts as a identifier on server side where you can authenticate user.",[11,91,92],{},[93,94],"img",{"alt":95,"src":96},"Diagram of a client holding cookies while the server reads and writes session data in Redis","https:\u002F\u002Fcdn-images-1.medium.com\u002Fmax\u002F1600\u002F1*Zr1CyFqSJLj0Mn0p-nyzWQ.png",[24,98],{},[27,100,102],{"id":101},"implementation","Implementation",[11,104,105,106,110,111,114,115],{},"We will use ",[107,108,109],"strong",{},"http cookies"," and ",[107,112,113],{},"Redis"," as data store, which will remove old stored sessions after they expire. You can use this for ",[44,116,118],{"href":117},"%5Bhttps:\u002F\u002Fgithub.com\u002Fgo-redis\u002Fredis%5D(https:\u002F\u002Fgithub.com\u002Fgo-redis\u002Fredis)","Redis Client",[11,120,121],{},[93,122],{"alt":123,"src":124},"Go code creating a user session with a UUID cookie and storing it in Redis","https:\u002F\u002Fcdn-images-1.medium.com\u002Fmax\u002F1600\u002F1*0Dswx4e6j_qrzpBQQW0pOQ.png",[11,126,127,128,132,133,138,139,142],{},"Here we first generate a ",[129,130,131],"code",{},"sessionID"," which is a random string. We then add cookie for sessionID via ",[44,134,137],{"href":135,"rel":136},"https:\u002F\u002Fgolang.org\u002Fpkg\u002Fcontext\u002F",[48],"context",". You can also add it via ",[129,140,141],{},"http.Request"," in your handler.",[11,144,145],{},"Then, we add a sessionUser which is a struct —",[147,148,153],"pre",{"className":149,"code":150,"language":151,"meta":152,"style":152},"language-go shiki shiki-themes github-light github-dark","type SessionUserClient struct {\n    UserID uint\n    Authenticated bool\n}\n\u002F\u002F You can add fields like \"Visitor count\", etc according to usecase\n","go","",[129,154,155,175,184,193,199],{"__ignoreMap":152},[156,157,160,164,168,171],"span",{"class":158,"line":159},"line",1,[156,161,163],{"class":162},"szBVR","type",[156,165,167],{"class":166},"sScJk"," SessionUserClient",[156,169,170],{"class":162}," struct",[156,172,174],{"class":173},"sVt8B"," {\n",[156,176,178,181],{"class":158,"line":177},2,[156,179,180],{"class":173},"    UserID ",[156,182,183],{"class":162},"uint\n",[156,185,187,190],{"class":158,"line":186},3,[156,188,189],{"class":173},"    Authenticated ",[156,191,192],{"class":162},"bool\n",[156,194,196],{"class":158,"line":195},4,[156,197,198],{"class":173},"}\n",[156,200,202],{"class":158,"line":201},5,[156,203,205],{"class":204},"sJ8bj","\u002F\u002F You can add fields like \"Visitor count\", etc according to usecase\n",[11,207,208,209,212],{},"Now, let’s persist the cookie value in our redis and store the ",[129,210,211],{},"SessionUser"," object. Here, I set the expiry time in cookie and redis for 180 seconds. You can change it, (say 24 hours)",[214,215,217],"h3",{"id":216},"how-to-retrieve-and-check-for-cookies","How to retrieve and check for cookies?",[11,219,220],{},[93,221],{"alt":222,"src":223},"Go code retrieving the session cookie and validating the authenticated user from Redis","https:\u002F\u002Fcdn-images-1.medium.com\u002Fmax\u002F1600\u002F1*5eerVUymsS2kQHWtakQFCg.png",[11,225,226],{},"Once a user hits a URL which requires authentication —",[38,228,229,232,235,238],{},[41,230,231],{},"We check if we received a cookie",[41,233,234],{},"Fetch the cookie value",[41,236,237],{},"Check in redis if the key exists.",[41,239,240,241,244,245],{},"Fetch the user and check if ",[129,242,243],{},"Authenticated"," param is set to ",[129,246,247],{},"true",[11,249,250,251,256],{},"Since, you want to check session over multiple page, adding a middleware seems a better option here. Read about implementing middleware ",[44,252,255],{"href":253,"rel":254},"https:\u002F\u002Fgowebexamples.com\u002Fadvanced-middleware\u002F",[48],"here",".",[24,258],{},[27,260,262],{"id":261},"time-to-test","Time to Test",[38,264,265,272,279],{},[41,266,267,268,271],{},"Create a ",[107,269,270],{},"\u002Fsignup"," route, where you create a session for user.",[41,273,274,275,278],{},"Create another ",[107,276,277],{},"\u002Fprofile"," route, add session auth middleware to this route. You’ll see you can access this page if you are logged in.",[41,280,281,282,285],{},"To refresh token, use ",[107,283,284],{},"\u002Fsignin"," page. Create new sessionID there and make a new entry to redis.",[11,287,288],{},"Now, you can add sessions to your new project. 😎",[11,290,291,292,297],{},"Liked the article? Consider ",[44,293,296],{"href":294,"rel":295},"https:\u002F\u002Fwww.buymeacoffee.com\u002FchHAzigTb",[48],"supporting me"," ☕️",[24,299],{},[11,301,302],{},"I hope you learned something new. Feel free to suggest improvements ✔️",[11,304,305,306,311],{},"I share regular updates and resources on ",[44,307,310],{"href":308,"rel":309},"https:\u002F\u002Ftwitter.com\u002Fmkfeuhrer",[48],"Twitter",". Let's connect!",[11,313,314],{},[107,315,316],{},"Keep exploring 🔎 Keep learning 🚀",[318,319,320],"style",{},"html pre.shiki code .szBVR, html code.shiki .szBVR{--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":152,"searchDepth":177,"depth":177,"links":322},[323,324,325,326,329],{"id":29,"depth":177,"text":30},{"id":59,"depth":177,"text":60},{"id":85,"depth":177,"text":86},{"id":101,"depth":177,"text":102,"children":327},[328],{"id":216,"depth":186,"text":217},{"id":261,"depth":177,"text":262},[331,332,333],"Golang","Database","Programming","How cookies and sessions work, and how to implement persistent login sessions in Golang using Redis.",false,"md","blog\u002Fsessions-in-golang\u002Fsessions-in-golang-card.webp","golang session cookie, golang session authentication, authentication in golang",{},"sessions-in-golang",true,"\u002Fblog\u002Fsessions-in-golang",{"title":5,"description":334},"blog\u002Fsessions-in-golang","2020-02-25","I_AhE8jSjLl-hK95P2jNJF_KeiWXx6nw4XbEYEWDv7U",[348,355,361,369,378,385,392,399,405,411,417,423,429,435,442,448,454,460,466,472,478,484,490,497,503,509,515,521,527,533,539,545,551,557,563,569,575,581,588,594,600,606,613,619,625,632,639,645,652,658,665,671,678,684,690,696,702,708,714,720,726,728,734,740,746,753,759,766,772,778,784,791,797],{"path":349,"title":350,"description":351,"categories":352,"draft":341,"year":354,"series":6},"\u002Fblog\u002Fai-assisted-workstation","Building an AI-Assisted Personal Workstation","A living log of building a practical AI-assisted workstation for software and startup work.",[353,333],"Productivity","2026-08-08",{"path":356,"title":357,"description":358,"categories":359,"draft":335,"year":360,"series":6},"\u002Fblog\u002Faws-s3-golang","Uploading images to AWS S3 in Golang","In this tutorial I cover how to upload, fetch and manage other operations for objects on AWS S3 in Golang",[331,333],"2020-01-12",{"path":362,"title":363,"description":364,"categories":365,"draft":335,"year":368,"series":6},"\u002Fblog\u002Fbooks-for-engineers","Best Books for Software Engineers","Best Books to help you build you software engineering career - ranging from fundamentats, interview prep to productivity.",[366,367],"Books","Life","2021-12-26",{"path":370,"title":371,"description":372,"categories":373,"draft":335,"year":377,"series":6},"\u002Fblog\u002Fbuilding-acrons","Building Acrons 🚀","Building Acrons, a one-stop tool to decode everyday acronyms like DIY, FOMO, and BRB without losing your flow.",[374,375,376],"Side Projects","Web","Tools","2020-05-26",{"path":379,"title":380,"description":381,"categories":382,"draft":335,"year":384,"series":6},"\u002Fblog\u002Fcap-theorem","CAP Theorem Explained","Learn the concept and misconceptions around popular CAP theorem in system design.",[383,333],"System Design","2021-07-26",{"path":386,"title":387,"description":388,"categories":389,"draft":335,"year":391,"series":6},"\u002Fblog\u002Fcode-reviews","Code Review Checklist","Why code reviews matter, and best practices that catch bugs early and keep code quality high before merge.",[390],"Engineering Principles","2020-07-20",{"path":393,"title":394,"description":395,"categories":396,"draft":335,"year":398,"series":6},"\u002Fblog\u002Fdark-mode","Add Dark mode to websites","Dark mode is ❤️️ Add it to your websites with little CSS and JS",[397,375],"Javascript","2020-07-04",{"path":400,"title":401,"description":402,"categories":403,"draft":335,"year":404,"series":6},"\u002Fblog\u002Fdate-time-golang","Working with Date and Time in Go","Learn how to use time in Golang - Multiple formats, locations and using date.",[331,333],"2020-10-09",{"path":406,"title":407,"description":408,"categories":409,"draft":335,"year":410,"series":6},"\u002Fblog\u002Fdefer-in-golang","Understanding Defer In Golang","Learn about defer keyword in golang and how it can help you avoid panics due to bugs.",[331,333],"2021-05-05",{"path":412,"title":413,"description":414,"categories":415,"draft":335,"year":416,"series":6},"\u002Fblog\u002Fenums-golang","Implementing Enums in Golang","Enums are a way to defined set of constant values. Learn how to implement enums in Go using iota with examples.",[331,333],"2021-12-18",{"path":418,"title":419,"description":420,"categories":421,"draft":335,"year":422,"series":6},"\u002Fblog\u002Fenvironment-variable-golang","Guide to Environment variables in Go","Learn what are environment variables and how to use them in Go",[331,333],"2020-08-14",{"path":424,"title":425,"description":426,"categories":427,"draft":335,"year":428,"series":6},"\u002Fblog\u002Ferror-handling-golang","Handle errors the right way — Golang","How to handle errors in golang to make your life easy",[331,333],"2020-01-30",{"path":430,"title":431,"description":432,"categories":433,"draft":335,"year":434,"series":6},"\u002Fblog\u002Ffile-upload-golang","Uploading Files in Golang with Multipart Request","Learn how to upload files from your client to server as a multipart request in Golang.",[331,333],"2021-03-13",{"path":436,"title":437,"description":438,"categories":439,"draft":335,"year":441,"series":6},"\u002Fblog\u002Fgit-branch","Git Branch 101","Branching is a new path of development that makes it a lot easier to build features. Learn why and how to use branching in git.",[440,333],"Git","2022-03-20",{"path":443,"title":444,"description":445,"categories":446,"draft":335,"year":447,"series":6},"\u002Fblog\u002Fgit-pull-request-template","Guide to Pull Request Templates","Improve collaboration and code reviews with pull request templates. Blog include PR template and how to create one on github\u002Fgitlab",[440,333],"2023-08-24",{"path":449,"title":450,"description":451,"categories":452,"draft":335,"year":453,"series":6},"\u002Fblog\u002Fgit-remove-sensitive-info","Securing Git: Remove Sensitive Information","Protect your code from security breaches by using BFG tool to remove sensitive information from Git history. Learn how to do it in this comprehensive guide.",[440,333],"2023-10-16",{"path":455,"title":456,"description":457,"categories":458,"draft":335,"year":459,"series":6},"\u002Fblog\u002Fgit-tags-explained","Git tags : Explained","What Git tags are, why and when to use them, and how to start tagging releases in your own projects.",[440,333],"2020-06-18",{"path":461,"title":462,"description":463,"categories":464,"draft":335,"year":465,"series":6},"\u002Fblog\u002Fgo-dependency-injection","Dependency Injection in Go using Wire","Learn about dependency injection, its benefits and how to implement it in Go services using wire",[331,333],"2022-11-26",{"path":467,"title":468,"description":469,"categories":470,"draft":335,"year":471,"series":6},"\u002Fblog\u002Fgo-generics","Introduction to Generics in Go","Learn about generics in Golang, it's benefits and how to implement it in applications.",[331,333],"2022-11-27",{"path":473,"title":474,"description":475,"categories":476,"draft":335,"year":477,"series":6},"\u002Fblog\u002Fgo-in-memory-cache","Building In-Memory Cache in Go","Learn about in-memory caching in Golang, it's benefits and how to implement it with and without generics with a TTL(expiry).",[331,333],"2024-03-28",{"path":479,"title":480,"description":481,"categories":482,"draft":335,"year":483,"series":6},"\u002Fblog\u002Fgo-makefile","Ultimate Makefile for Golang","Boost your productivity and save time with ultimate Makefile for Golang projects.",[331,333],"2024-06-10",{"path":485,"title":486,"description":487,"categories":488,"draft":335,"year":489,"series":6},"\u002Fblog\u002Fgo-middleware","Mastering Middlewares in Golang","Learn about middlewares, their use cases and how to implement them in Golang applications",[331,333],"2022-03-13",{"path":491,"title":492,"description":493,"categories":494,"draft":335,"year":496,"series":6},"\u002Fblog\u002Fgo-naming-conventions","Naming Conventions in Golang","Why naming conventions matter in Go, with best practices and practical examples for clear, readable, maintainable code.",[331,333,495],"Code Quality","2023-05-19",{"path":498,"title":499,"description":500,"categories":501,"draft":335,"year":502,"series":6},"\u002Fblog\u002Fgo-with-redis","Go with Redis","A practical introduction to using Redis with Golang to make your applications faster with in-memory data storage.",[331,332,333],"2020-05-03",{"path":504,"title":505,"description":506,"categories":507,"draft":335,"year":508,"series":6},"\u002Fblog\u002Fgolang-maps","Learn Maps in Golang (with examples)","A complete guide to maps in Golang: creating maps, adding and removing items, iterating, and how map equality works.",[331,333],"2020-09-10",{"path":510,"title":511,"description":512,"categories":513,"draft":335,"year":514,"series":6},"\u002Fblog\u002Fguide-to-cdn","Guide to Content Delivery Network","CDN is one of the backbone of modern world internet infrastructure. Learn about Content Delivery Network, it's working, types and benefits.",[383,333],"2022-01-23",{"path":516,"title":517,"description":518,"categories":519,"draft":335,"year":520,"series":6},"\u002Fblog\u002Fguide-to-rule-engines","Guide to Rule Engines","Rule Engines help in solving changing business requirements with ease. Learn all about Rule engines, it's working, benefits and how to implement one in Golang",[331,333],"2022-09-12",{"path":522,"title":523,"description":524,"categories":525,"draft":335,"year":526,"series":6},"\u002Fblog\u002Fhexagonal-architecture","Guide to Hexagonal Architecture","Learn how to design efficient application with hexagonal architecture with practical example",[383,333],"2020-12-13",{"path":528,"title":529,"description":530,"categories":531,"draft":335,"year":532,"series":6},"\u002Fblog\u002Fhttp-status-codes","Learn HTTP Status Codes","A tour of HTTP response status codes, what each class means, and when to use which code in your applications.",[375,333],"2020-07-30",{"path":534,"title":535,"description":536,"categories":537,"draft":335,"year":538,"series":6},"\u002Fblog\u002Fintroduction-to-goroutines","Introduction to Goroutines","Understand the basics of concurrency and learn how to work with Goroutines in golang.",[331,333],"2021-04-10",{"path":540,"title":541,"description":542,"categories":543,"draft":335,"year":544,"series":6},"\u002Fblog\u002Fjson-in-postgres-with-golang","Storing JSON in Postgres with Golang","Learn how to store JSON objects in Postgres and how to implement it in Golang.",[333,332,331],"2021-02-13",{"path":546,"title":547,"description":548,"categories":549,"draft":335,"year":550,"series":6},"\u002Fblog\u002Fjson-web-token","Complete Guide to JWT","JSON Web Tokens are a very compact way to carry information. Learn about JWTs in depth, from its structure to when to use it.",[333,375],"2021-11-20",{"path":552,"title":553,"description":554,"categories":555,"draft":335,"year":556,"series":6},"\u002Fblog\u002Flearn-to-say-no","Learning to say No","Learn why it's important to say 'NO'. How it helps in increasing productivity and explore strategies for saying No",[367,366],"2022-04-09",{"path":558,"title":559,"description":560,"categories":561,"draft":335,"year":562,"series":6},"\u002Fblog\u002Flearn-unlearn-relearn","Learn - Unlearn - Relearn","Unlearning things to learn new is the way to grow. Discover how to do that!",[353,367],"2020-09-25",{"path":564,"title":565,"description":566,"categories":567,"draft":335,"year":568,"series":6},"\u002Fblog\u002Flinting-in-golang","Introduction to Linting in Go","Introduction to improving code quality using linting. Learn how to add linting in your Go projects.",[331,333],"2021-07-07",{"path":570,"title":571,"description":572,"categories":573,"draft":335,"year":574,"series":6},"\u002Fblog\u002Fload-balancing","Load Balancing 101","Complete guide on load balancers explaining the internal working and how does it help in making applications efficient.",[383,333],"2021-05-29",{"path":576,"title":577,"description":578,"categories":579,"draft":335,"year":580,"series":6},"\u002Fblog\u002Fmaking-decisions-the-right-way","Making Decisions: The right way","Decisions are hard! Learn how to make the right decisions always",[353,367],"2020-06-07",{"path":582,"title":583,"description":584,"categories":585,"draft":335,"year":587,"series":6},"\u002Fblog\u002Fmanage-logs-with-logrotate","Using Logrotate to manage logs","Learn how to use logrotate system utility to manage logs with example",[586,333],"Linux","2020-09-08",{"path":589,"title":590,"description":591,"categories":592,"draft":335,"year":593,"series":6},"\u002Fblog\u002Fmarshal-structs-golang","Marshal structs the right way: Golang","Why Golang marshals empty structs into your JSON instead of null, and how to marshal structs the right way.",[331,333],"2020-03-31",{"path":595,"title":596,"description":597,"categories":598,"draft":335,"year":599,"series":6},"\u002Fblog\u002Fnotes-almanack-naval","Book Notes : Almanack of Naval Ravikant","My notes\u002Fhighlights from Almanack of Naval Ravikant book by Eric Jorgenson",[366,367],"2020-10-17",{"path":601,"title":602,"description":603,"categories":604,"draft":335,"year":605,"series":6},"\u002Fblog\u002Fnotes-anything-you-want","Book Notes : Anything you want","My notes\u002Fhighlights from Anything you want book by Derek Sivers",[366,367],"2021-09-25",{"path":607,"title":608,"description":609,"categories":610,"draft":335,"year":612,"series":6},"\u002Fblog\u002Fnotes-getting-real","Book Notes : Getting Real","My notes and highlights from Getting Real by Jason Fried and David Heinemeier Hansson on building web applications.",[366,611],"Startups","2020-11-03",{"path":614,"title":615,"description":616,"categories":617,"draft":335,"year":618,"series":6},"\u002Fblog\u002Fnotes-hell-yeah-or-no","Book Notes : Hell Yeah or No","My notes\u002Fhighlights from Hell Yeah or No book by Derek Sivers",[366,367],"2020-09-16",{"path":620,"title":621,"description":622,"categories":623,"draft":335,"year":624,"series":6},"\u002Fblog\u002Fnotes-how-to-be-a-capitalist","Book Notes : How to Be a Capitalist Without Any Capital","My notes\u002Fhighlights from How to Be a Capitalist Without Any Capital by Nathan Latka",[366,611],"2020-01-07",{"path":626,"title":627,"description":628,"categories":629,"draft":335,"year":631,"series":6},"\u002Fblog\u002Fnotes-lean-b2b","Book Notes : Lean B2B","My notes and highlights from Lean B2B by Étienne Garbugli on assessing markets, building MVPs, and selling to businesses.",[366,630],"Entrepreneurship","2022-07-02",{"path":633,"title":634,"description":635,"categories":636,"draft":335,"year":638,"series":6},"\u002Fblog\u002Fnotes-lets-talk-money","Book Notes : Let's Talk Money","My notes and highlights from Let's Talk Money by Monica Halan on managing personal finances and savings.",[366,637],"Personal Finance","2021-02-26",{"path":640,"title":641,"description":642,"categories":643,"draft":335,"year":644,"series":6},"\u002Fblog\u002Fnotes-obviously-awesome","Book Notes : Obviously Awesome","My notes and highlights from Obviously Awesome by April Dunford on product positioning and marketing strategy.",[366,611],"2020-04-26",{"path":646,"title":647,"description":648,"categories":649,"draft":335,"year":651,"series":6},"\u002Fblog\u002Fnotes-refactoring-ui","Book Notes: Refactoring UI","My notes and highlights from Refactoring UI by Adam Wathan and Steve Schoger, full of practical design tips for engineers.",[366,650],"Design","2020-05-09",{"path":653,"title":654,"description":655,"categories":656,"draft":335,"year":657,"series":6},"\u002Fblog\u002Fnotes-rework","Book Notes: Rework","My notes and highlights from Rework by Jason Fried and David Heinemeier Hansson on a better way to succeed in business.",[366,611],"2021-04-14",{"path":659,"title":660,"description":661,"categories":662,"draft":335,"year":664,"series":6},"\u002Fblog\u002Fone-on-one-meetings","Guide to Effective 1:1 Meetings","One on One meetings are important for your personal & professional growth. Learn how to master 1:1s with your manager and peers.",[663,353],"Career","2023-03-05",{"path":666,"title":667,"description":668,"categories":669,"draft":335,"year":670,"series":6},"\u002Fblog\u002Fpersonal-okrs","Personal OKRs for Success","Why one should set personal OKRs and how to achieve success with them",[353,367],"2020-06-27",{"path":672,"title":673,"description":674,"categories":675,"draft":335,"year":677,"series":6},"\u002Fblog\u002Fpoker-tips","Poker Tips: Johns Hopkins Poker Class","Notes from Johns Hopkins poker course. This guide will help you improve in Poker and win some large pots.",[367,676],"Poker","2020-06-13",{"path":679,"title":680,"description":681,"categories":682,"draft":335,"year":683,"series":6},"\u002Fblog\u002Fpomodoro","Get work done: The Pomo Way","Learn to focus and get productive by following the Pomodoro Technique",[353],"2020-10-24",{"path":685,"title":686,"description":687,"categories":688,"draft":335,"year":689,"series":6},"\u002Fblog\u002Fpostgres-constraints","Postgres Constraints","Constraints are line of defense for database. Explore various types of constrainsts in postgres",[332,333],"2020-11-07",{"path":691,"title":692,"description":693,"categories":694,"draft":335,"year":695,"series":6},"\u002Fblog\u002Fppf-explained","PPF Explained","Learn basics about Public Provident Fund and why you should invest",[367,637],"2020-12-24",{"path":697,"title":698,"description":699,"categories":700,"draft":335,"year":701,"series":6},"\u002Fblog\u002Fproductivity-chrome-extensions","Boost Productivity with Chrome Extensions","Utitizing chrome extensions to boost your productivity!",[353,376,375],"2020-04-24",{"path":703,"title":704,"description":705,"categories":706,"draft":335,"year":707,"series":6},"\u002Fblog\u002Fproductivity-in-vscode","Improve your productivity with VS Code","Key VS Code features like the integrated terminal, shortcuts, and extensions that improved my everyday productivity.",[353,333],"2020-03-12",{"path":709,"title":710,"description":711,"categories":712,"draft":335,"year":713,"series":6},"\u002Fblog\u002Freading-101","Improving Reading 101","Why reading matters, how to build a reading habit, and what to read next - from my own journey into books.",[366,367],"2020-04-04",{"path":715,"title":716,"description":717,"categories":718,"draft":335,"year":719,"series":6},"\u002Fblog\u002Freverse-proxy","Understanding Reverse Proxy","Learn about reverse proxy, how it is different from forward proxy and explore advantages of using it in system design.",[383,333],"2021-10-03",{"path":721,"title":722,"description":723,"categories":724,"draft":335,"year":725,"series":6},"\u002Fblog\u002Frunning-periodic-background-task-golang","Running periodic background tasks in Golang","How to run periodic background tasks in Golang by combining cron-style scheduling with background execution.",[331,333],"2019-11-21",{"path":342,"title":5,"description":334,"categories":727,"draft":335,"year":345,"series":6},[331,332,333],{"path":729,"title":730,"description":731,"categories":732,"draft":335,"year":733,"series":6},"\u002Fblog\u002Fsolid-dry-kiss-yagni","Solid Dry Kiss Yagni","An introduction to the SOLID, DRY, KISS, and YAGNI principles and how they help you write cleaner, robust code.",[390],"2020-07-17",{"path":735,"title":736,"description":737,"categories":738,"draft":335,"year":739,"series":6},"\u002Fblog\u002Fstack-in-golang","Implement Stack in Golang","Learn how to implement stack data structure in Golang (Full code)",[331,333],"2020-09-14",{"path":741,"title":742,"description":743,"categories":744,"draft":335,"year":745,"series":6},"\u002Fblog\u002Fstart-oss-today","Start your Open Source journey today","Start your OSS journey with intro to GIT. Participate in Hacktoberfest!",[440,333],"2020-09-19",{"path":747,"title":748,"description":749,"categories":750,"draft":335,"year":752,"series":6},"\u002Fblog\u002Fsticky-social-bar","Sticky social share component in HTML","Learn how to build a social media sharing component in HTML and add it to your website.",[333,751],"Frontend","2021-02-05",{"path":754,"title":755,"description":756,"categories":757,"draft":335,"year":758,"series":6},"\u002Fblog\u002Fterm-insurance","Term insurance Simplified","Everything you need to know before you buy a term insurance.",[367,637],"2020-11-29",{"path":760,"title":761,"description":762,"categories":763,"draft":335,"year":765,"series":6},"\u002Fblog\u002Fterminal-output-with-redirection","Handling terminal outputs with Redirection","Learn how to handle terminal outputs with Redirection and saving it to files",[586,764,333],"Terminal","2020-09-06",{"path":767,"title":768,"description":769,"categories":770,"draft":335,"year":771,"series":6},"\u002Fblog\u002Fthink-and-grow-rich","Book Notes: Think and Grow Rich","My notes and highlights from Think and Grow Rich by Napoleon Hill, covering its process for building wealth.",[366,367],"2020-05-19",{"path":773,"title":774,"description":775,"categories":776,"draft":335,"year":777,"series":6},"\u002Fblog\u002Ftransactions-postgres-golang","Transactions on Postgres with Golang","Performing Postgres database operations in Golang with GORM, from basic queries to full transaction support.",[331,332,333],"2020-03-18",{"path":779,"title":780,"description":781,"categories":782,"draft":335,"year":783,"series":6},"\u002Fblog\u002Fwaitgroups-in-golang","WaitGroups in Golang","Learn about WaitGroups in golang and how to use them to perform concurrent operations without blocking the main thread.",[331,333],"2022-05-31",{"path":785,"title":786,"description":787,"categories":788,"draft":335,"year":790,"series":6},"\u002Fblog\u002Fwhat-i-use","What I Use: Products and Softwares","List of what I use in my day to day life ranging from terminal, editors, softwares, devices to accessories",[367,789],"Tech","2024-06-01",{"path":792,"title":793,"description":794,"categories":795,"draft":335,"year":796,"series":6},"\u002Fblog\u002Fyear-in-review-2020","Year in Review: 2020","It's a wrap! 2020 was a crazy year, See how my year went!",[367],"2020-12-31",{"path":798,"title":799,"description":800,"categories":801,"draft":335,"year":802,"series":6},"\u002Fblog\u002Fyear-in-review-2021","Year in Review: 2021","It's a wrap! 2021 was a mixed bag, full of ups and downs. Key Goal for 2022: Start now!",[367],"2021-12-31",1787743428736]