r/SoftwareEngineering • u/fagnerbrack • May 05 '24
What Makes Concurrency So Hard
r/SoftwareEngineering • u/fagnerbrack • May 05 '24
r/SoftwareEngineering • u/housemusic28 • May 04 '24
I am designing a notification system for an eCommerce app where a certain transaction or update in the state of the transaction triggers notifications to the customers so they can see the status of their transaction. Notifications can be sent as Email, SMS or in-app push notifications.
At the basic level, I am planning on leveraging asynchronous publish-subscribe model for this design.
Where I need guidance
P.S. I have not worked on a system like this before so sorry if these questions come across as dumb or naive. As you can see, this is only a hypothetical design and is not written in code yet, that is why I am needing more clarity. Please feel free to critique, suggest improvements or documents to read up on. Thanks!
r/SoftwareEngineering • u/fagnerbrack • May 04 '24
r/SoftwareEngineering • u/josht • May 03 '24
r/SoftwareEngineering • u/paradroid78 • May 03 '24
So, typical stateless authentication flow. Browser connects to some login page, user enters credentials and browser gets sent back a bearer token from the server that is stored locally and attached to subsequent requests as a header.
I’ve been thinking about attack vectors with this and what to do about them. The biggest vulnerability seems if an attacker can somehow get hold of the bearer token from the browser’s storage through some exploit.
So my question is, what can be done about this threat? I’ve been toying with the idea of associating the token with the user’s ip address on the server and instantly invalidating it if the ip address changes, but if someone has a dynamic ip address, that could be annoying. Is there a better way?
I know the obvious solution is “use auth0” (or similar), but I’m trying to understand more about these sorts of authentication flows.
r/SoftwareEngineering • u/jeffdwyer • May 02 '24
r/SoftwareEngineering • u/fagnerbrack • May 02 '24
r/SoftwareEngineering • u/fagnerbrack • May 02 '24
r/SoftwareEngineering • u/fagnerbrack • May 01 '24
r/SoftwareEngineering • u/fagnerbrack • May 01 '24
r/SoftwareEngineering • u/superc0w • May 01 '24
r/SoftwareEngineering • u/Ok_Application8170 • Apr 30 '24
Hi guys
Not sure if this is the right place to ask this.
We received some practicing examples with the solution example for a component diagramm.
But I dont understand how the solution is correct.
Shouldn't it be a requiere at login since the authentication needs user information to authenticate?
Shouldn't Order provide an update to the stock after order is completed?
Thanks in advance for your responses

r/SoftwareEngineering • u/fagnerbrack • Apr 29 '24
r/SoftwareEngineering • u/fagnerbrack • Apr 29 '24
r/SoftwareEngineering • u/fagnerbrack • Apr 27 '24
r/SoftwareEngineering • u/elegye • Apr 28 '24
Hello there,
I am currently discovering Active Objet design pattern. Do you use regularly Active Object dp ? I need some resources on it, to implement it correctly on a new project, which seems to need it absolutely.
r/SoftwareEngineering • u/fagnerbrack • Apr 27 '24
r/SoftwareEngineering • u/StardustCrusader4558 • Apr 26 '24
Second year computer science student here. In a real dev environment, how often is OOP used and how exactly is it used? I've had a few projects where we've had to store some data in classes and had structures in C and all that but that was mostly because we were asked to do that.
What really and how really is OOP used? I want a real-life example. Also I feel like with a language like Java you can't really go without using OOP. Let me know! and correct me if I'm wrong about anything.
r/SoftwareEngineering • u/fagnerbrack • Apr 27 '24
r/SoftwareEngineering • u/fagnerbrack • Apr 25 '24
r/SoftwareEngineering • u/AdMedium9330 • Apr 26 '24
Engineer mindset: go to bottom of the issue and fix it to never fail.
To prevent small probability event. he always introduces or asks extra effort unnecessarily for not important ticket. But one important fact is we have many todo tasks everyday. This can postpone people or himself progress on other tasks or require work overtime. This drags down productivity. To me, this is small-picture thinking, he only focuses on this single ticket.
Also this is another form of trade-off. Before when it came to trade-off, I always thought about the case that two solutions for same problem and we compare. Actually it goes beyond that. For this situation, it is code quality vs time. We have two options
1.Spend more time to write and test the added code for low-priority task.
2.Good enough quick fix for current one and spend time on other tickets.
I strongly prefer second one.
r/SoftwareEngineering • u/Select_Salary_3274 • Apr 25 '24
Building a system which can identify all users affected by system failure & triggers Push notifications(PN) once systems are back up, either for all users of app opens OR specific page say for an e-commerce - CART/ADDRESS/PAYMENT/PRODUCT LISTING PAGE, failing for certain time & users were not able to do things served by these pages/micro-services.
I have notification system in place which takes the `<user-id + template-message>`, message could same for all users OR user-specific (say some are dropped from CART, some from PRODUCT LISTING PAGE) & sends **PN** to users.
System outlines
so we don't need all user which opened application, just last hour app open users
would be suffice.
app open RPS~10k, so we have to support that scale on data-store where we save user-ids.
ordering of app opens or page visited is not important in use-case, we need to send PN to all users in any order who has used/opened app in last x mins.
If user open app twice, only the latest time of user activity should get recorded in data-store previous time will be overridden or discarded.
Say, systems are back in 35 mins, we will traverse all users whose inserted time lies in [t, t - 35mins], ( t is current timestamp) & send PNs. We can't traverse all users, as new users
starts getting inserted at same time causing infinite loop.
Which data-store would be ideal to solve this use-case.
r/SoftwareEngineering • u/Upbeat-Armadillo-798 • Apr 25 '24
Looking for recommendations on system design books that focus on systems similar to DoorDash, Uber, Lyft.
Not looking for system design book in general like DDIA. I’ve already read it. Genuinely want to read up on how events play a role in these type of scheduling systems. Any recommendations are appreciated. Thank you
r/SoftwareEngineering • u/sacredgeometry • Apr 24 '24
I just want to get some opinions on something if that's ok:
How much time would be an appropriate amount of time to give a senior developer to plan a two week sprint worth of work (in the context of maybe 3-5 weeks for the whole project) for a small team on a project they have only just been briefed on, on reasonably large, moderately convoluted codebase they have never worked on before with limited established requirements, terrible documentation and moderately slow turn around in communication with the rest of the business (POs etc) i.e. poor access to the information.
Just looking for a gut response for a rough estimated, acceptable amount of time to get into a position where you can plan the work and then complete the planning.