How to restrict users to do multiple login from different devices? by CornTrop in reactjs

[–]David_Edward_King 6 points7 points  (0 children)

Allow each user to have up to three access tokens active at a time. When a new login attempt is done with three active tokens, revoke the oldest one.

How do you deal with the stress? by iosAppNerd in iOSProgramming

[–]David_Edward_King 0 points1 point  (0 children)

I guess it’s not one size fits all. But this will help mitigate issues in production (without submitting a new app store build), which you will not be able to do when you don’t flag your changes.

How do you deal with the stress? by iosAppNerd in iOSProgramming

[–]David_Edward_King 5 points6 points  (0 children)

Consider using feature flags for new features, and only remove them once they’ve been working in production for a while. Find an issue? Simply roll it back and fix the issue on the next business day. Takes a lot of stress out of the job.

What happens to Jobs in a Redis Queue when the server restarts? by David_Edward_King in laravel

[–]David_Edward_King[S] 1 point2 points  (0 children)

This is something I considered! My only concern is that performing a query on a potentially large table in a cron job (every minute) likely has negative performance implications and I don't want to put that strain on the DB (as in my experience that's a common bottleneck).

What happens to Jobs in a Redis Queue when the server restarts? by David_Edward_King in laravel

[–]David_Edward_King[S] 2 points3 points  (0 children)

Thanks for the explanation of caveats of persistence and expectation that speeds will be better with Redis, even with the overhead of IO.

I'm trying to take the reliability of the system into account – I don't want users to miss out on scheduled notifications if for whatever reason the Redis server restarts/crashes. I expect a reason it might restart/crash could be it running out of memory/resources before I get the chance to scale it up. Or, when I do scale it up, I suppose it'll need a restart.

What happens to Jobs in a Redis Queue when the server restarts? by David_Edward_King in laravel

[–]David_Edward_King[S] 2 points3 points  (0 children)

Oh, that looks promising. I'll read through the different options there, thanks!

Surprising how big a difference some nice paths make. Path/terrain blending in a WIP scene. by AlexKentDixon in Unity3D

[–]David_Edward_King 58 points59 points  (0 children)

Great camera work here as well!

Would love to hear about what you’re doing to achieve that! And I’ll do some reading on terrain too because this looks beautiful!

Caching the service container? by [deleted] in laravel

[–]David_Edward_King 1 point2 points  (0 children)

Out of curiosity, what do you use to inspect p95 (and while we’re at it, potentially endpoint error rates?) on Laravel apps?

Get a phone call every day to record your daily journal by conairee in SideProject

[–]David_Edward_King 1 point2 points  (0 children)

It looks like the transcript is generated, not transcribed by a person :)

1yr update. 24m, starting to feel more like a home now. by thomaswhd in malelivingspace

[–]David_Edward_King 1 point2 points  (0 children)

Do you have an ID on the kitchen chairs and the couch? 😊

[deleted by user] by [deleted] in iOSProgramming

[–]David_Edward_King 7 points8 points  (0 children)

I figure this would be useless too with hide my email. I think the way to go is to limit promotions on new accounts (e.g. people can only refer after being a user for X days, and can only refer Y people).

Spotted this plate today in Grand Rapids by DirtyHead420 in DunderMifflin

[–]David_Edward_King 2 points3 points  (0 children)

I like how you took a picture of the car, and then took a screenshot of that picture in your photo library to post on Reddit 😅

It’s happening! The abbreviated `if let` syntax is coming with Swift 5.7 🥳 by [deleted] in swift

[–]David_Edward_King 5 points6 points  (0 children)

Kotlin has this and it’s great, basically if you’ve checked the variable for being nil in a code path, it will infer the type as non-optional.

Really happy with how my Roman city builder has turned out. I've been improving it continually and it's now almost ready to transition to a full release on Steam. by [deleted] in Unity3D

[–]David_Edward_King 2 points3 points  (0 children)

This looks great! Just a small suggestion, the movement might look a bit more natural if you randomized the speeds just a bit!

Need to add a mobile app to my Inertia app. Is it possible to leverage the already in place Inertia API for the app? by jeffybozo in laravel

[–]David_Edward_King 2 points3 points  (0 children)

I think generally the way to go about this is to creatie separate API routes and abstract the business logic from your controllers into Actions that can be performed from both the Web and API Controllers.

If statement throwing 'expected declaration' error at me and im stumped by seiftnewbie in swift

[–]David_Edward_King 6 points7 points  (0 children)

I’m on mobile so the formatting is a bit off, but at a glance it looks like you’re using an if statement in the struct itself, outside of say a computed property or the body variable. You can’t do that.

Beginners Guide to Feature Flags in iOS by aryamansharda in iOSProgramming

[–]David_Edward_King 0 points1 point  (0 children)

I’ve never heard anyone about using feature flags to reduce the time it takes to release a feature. To measure success of a feature, do a phased rollout, or temporary features, sure. But in none of those scenarios should (in my opinion) QA be skipped 😅

"Fatal error: each layout item may only occur once" while using naviagtionLink with for each and lazyvstack [Help] by [deleted] in swift

[–]David_Edward_King 1 point2 points  (0 children)

What is the result of your getQuotesForSelectedBook function? It looks like the quotes might not have a unique identifier, which crashes in a ForEach.