andreyka26_se
1.15K subscribers
1.25K photos
165 videos
9 files
718 links
Hey, I'm software engineer at Microsoft, with 8+ years of experience. Here we are talking about F(M)AANG big tech interviews: leetcode, system design and corpo life.

YouTube: @andreyka26_se
Instagram: andreyka26_se
TikTok: @andreyka26__
Download Telegram
Story of how agent failed

We have our own automation tool, sort of airflow. I needed to change some stuff in the cloud. We have crazy complicated way of doing that, looks more like what I have on the picture.

I was prompting (grok 4.7, cursor) , asking to check our docs, slack, etc and give me a way how to do a change, test/validate it, and be sure it will work.

It gave me good looking but not working plan all the time, no proper test plan, missed release cycles etc.

I talked to my colleague who had hands on exp with that - in 5 mins I got the plan how to do it which is SOOO different from what AI gave me.

#ai #aifailed
👍3❤1
I have seen this q in Threads:

Tech interview questions | Database

The orders table has ~50 million rows. You need to add a new column is_gift with a default value of false.

A developer ran the migration, and after 10 seconds the entire service stopped responding, even for reading orders. The migration process had to be killed.
How should this migration be done correctly?
❤4👍1
andreyka26_se
I have seen this q in Threads: Tech interview questions | Database The orders table has ~50 million rows. You need to add a new column is_gift with a default value of false. A developer ran the migration, and after 10 seconds the entire service stopped…
The expected answer probably implies some db knowledge, potentially avoiding index creation, and potentially going with NULL first.

BUT

The actual way of doing it if you respect customers, your engineers and oncall - is typical 3 step migration:

Bring new storage with new field. Hydrate it with existing data

1. Write to both, read from first storage
2. Write to both, read from second storage
3. Write and read from second storage (that has flag)


Worked on 1M rps. Applies regardless of storage type.
❤5
andreyka26_se
The expected answer probably implies some db knowledge, potentially avoiding index creation, and potentially going with NULL first. BUT The actual way of doing it if you respect customers, your engineers and oncall - is typical 3 step migration: Bring new…
It must be done with feature flags IN THE CODE.

This way you control where and when you enable migration step, you have monitoring, and THE MOST IMPORTANT: you can rollback any time
❤4
Good luck with that.

Actually number of records is irrelevant. It is about reliability.

You can never be sure your migration will work without error 100% on prod instance.

If it does not - you have downtime, lost data(as recovery is from backup, or roll forward the fix, that might not work as well).

You dont have control and monitoring. In sharded env - again, you cannot do it atomically on multiple shards.

Aaand it does not work for all types of migration/storages (it can be much more complicated than boolean field)

Especially on highload systems - never do that. Always do 3 steps approach
❤3👍1
andreyka26_se
Good luck with that. Actually number of records is irrelevant. It is about reliability. You can never be sure your migration will work without error 100% on prod instance. If it does not - you have downtime, lost data(as recovery is from backup, or roll…
Yes, let me correct myself.
Volodymyr is right about that specific case.

Probably nothing will happen and it will work on single db(with low rps)

I would go that way ONLY
- if I can afford downtime + backup + losing data
- If I am okay to be down until I hot fox and roll forward

Otherwise - 3 steps.
❤2
After I worked some years

I just hope software for healthcare and airplanes along with defence area is built differently
❤6
This media is not supported in your browser
VIEW IN TELEGRAM
Would you come to me as to doctor, if I am same quality doc as I am engineer?😆😆😆😆😆
👍4❤1
Someone has sent me.

The problem is that similar thoughts I have heard from ex-Google director, currently Principal at Snow….
❤1🤯1
The guy is from Moldova. We had a Leetcode mock interview in the beginning of the summer.

Now he relocated to Ireland, interviewing with many companies, and eventually we met in person in noname coworking, cause Snowflake does not have nice office to show😆

Let’s wish him offers, as market in Ireland at least is not that great.
❤20👍5
So was it 2026 instead of 2015?)
😁10
Daily 434th day streak

Interesting and unique problem.
Was pretty hard for me to build an intuition. But solution has pattern, so I would recommend.

https://leetcode.com/problems/minimum-swaps-to-sort-by-digit-sum/description/?envType=daily-question&envId=2026-10-17

#daily #medium #pattern
❤2
Had to show my CT scan to Ukrainian friend. Wanted to make it as easy as possible to see that scan so no need to install any app, etc

This is why I love about AI. 15 mins + my manual deployment: here you go, you have CT scan viewer. Just like that. Everyone can do it. Cheap and easy. Scary... and good at the same time

Btw look how big my heart is😁 I thought it is smaller.
❤7🤯1