Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

krisi_gjika's avatar

krisi_gjika wrote a comment+100 XP

2mos ago

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

4mos ago

What do you prefer to choose?

Than bring it up to him in a nice way that you do not think it is necessary to implement repository pattern since eloquent already abstracts data retrieval. But if they are set on it, the reality is you can't do much about it. Use it like they suggest, while a bit overkill it's not a bad pattern to have under your tool belt.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Weird behavior with mysql

why do you need to make table engine as InnoDB for gifts table?

are the other tables not InnoDB as well? I don't think you can have foreign keys between different engines.

krisi_gjika's avatar

krisi_gjika liked a comment+100 XP

5mos ago

Getting all Sessions for given user from Redis

Sorry to raise this post from the dead, but I just published a package that makes this doable. It updates the DB (you control how often with a configurable throttle) so that redis sessions can be tracked/listed/destroyed.

User Agent enrichment happens automatically, and you can optionally install the MaxMind GeoLite2 DB and get Location detail too.

100% type coverage, test coverage, and phpstan at level 9.

https://github.com/willvincent/laravel-session-manager

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Laravel 12 – php artisan schedule:run causes periodic CPU spikes even with no scheduled tasks

what is your session driver? do you have some specific setup where file or database deletes are expensive?

if you can't do anything else, you can at least use a driver that does auto clearing of old data for you.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Is it required to code an entire module like a basic "Instant Messenger" for example in coding interviews as quick and accurate as possible?

If you are applying for the role of "Laravel Developer" you are expected to know Laravel. Than depending on the required experience, you are expected to know things around the framework or ecosystem you will be working on.

Read the actual description and requirements of the position to have an understanding of what is expected of you. Example one position might expect you to also know some frontend framework, others might not care at all about that and expect you to know something else, it's not fixed.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

PHPStan Level 9 is killing me with DTOs — please roast my code (GitHub link inside)

you have a lot of code there, can you give a specific example you are having trouble with?

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

PHPStan Level 9 is killing me with DTOs — please roast my code (GitHub link inside)

since you are using max level I really hope you are actually using larastan

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Should I only add complexity when there are issues with the Web System itself and start off simple and follow YAGNI and the Evolutionary Architecture?

(like AWSs EC2, Cloud Formation, ELB, Auto-Scaling, ECS, EKS, IAM, RDS, S3 if using this Storage, etc...), most of these Services are a requirement not added when needed - all of that is optional tho, you don't need every AWS service to run a server. The cloud saved us so much money we can almost afford the team to run it mentality

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

How to Implement a Unique “Like” System in Laravel Without User Registration?

I would not recommend auth here, it has way more friction. You ask for user to provide email and password, and also verify his email, and than go back and like your post.

By that point a lot of users have given up if having an account in your portfolio serves no other purpose. Compare that to only sending an email or sms and verifying there.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

How to Implement a Unique “Like” System in Laravel Without User Registration?

you need to ask something unique from the user to be able to have unique functionality like unique likes.

even when they don't authenticate, you can still ask for an email address or phone number to send a verification link. only after clicking that link you can do your checks for uniqueness consider their like to be valid.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Issues working between Linux and Windows environments

why couldn't he install pcntl extension?

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Laravel Authentication partially working

your session does not have a "login_web_*****" key here, so you are not logged in.

krisi_gjika's avatar

krisi_gjika wrote a reply+100 XP

5mos ago

Return Object rather than Array of stdout

can you show an example of your dataset, and what are you trying to query from it? What is the resulting response you expect? What do you mean by "they all appear to find the latest before filtering by date"? Why do you need "->select(DB::raw('DISTINCT ON(packaging_id) *'))"?