Instagram story viewer> @blackcask_> Posts
154
posts
21.7K
followers
0
following
Code • Life • Travel
MANASA VACHA KARMANA
POSTS STORIES REELS TAGGED
Download All
Day 6/31-365 follow for more content.Uber : Stateless Design -> New OTP + ride id check - prevent replay attackRapido : chekcs Driver id + session id + ride id + otp.🚘Uber: Uber creates a new OTP for every rideThat OTP is linked only to that specific tripOnce the ride is done or expired → OTP is useless👉 Think of it like a one-time ticket per rideWhy? → Strong security, no reuse possible - Stateless design.🛵 Rapido (Simple Explanation)Rapido shows you the same OTP again and againBut it is checked along with your ride and accountSo even if OTP looks same, it only works for your current ride👉 Think of it like a fixed PIN + ride contextWhy? → Faster, simpler, less system load.Analogy : Uber otp - new movie ticketRapido otp : Atm pin.#fyp #viral #trending #tech #explore by @blackcask_
65
3 months ago
Download
Day 3/31-365 follow for more such content..If an API works in Postman but fails in the browser, it’s usually due to environment differences (headers, CORS, auth, cookies, etc.).✅ If API works in Postman but fails in Browser:1️⃣ CORS issue (Most common)Browser blocks cross-origin requests, Postman doesn’t. Backend must allow frontend origin.2️⃣ Preflight (OPTIONS) not handledBrowser sends an OPTIONS request first. If server doesn’t allow it → request fails.3️⃣ Missing HeadersAuthorization, Content-Type, or custom headers may not be sent from frontend properly.4️⃣ Authentication issueToken or cookies may not be attached in browser request.5️⃣ HTTPS vs HTTP (Mixed Content)Browser blocks HTTP APIs when frontend is running on HTTPS.6️⃣ CSRF ProtectionBackend may require CSRF token for browser requests.7️⃣ Cookie / SameSite policyBrowser enforces cookie security rules, Postman doesn’t.8️⃣ Wrong API URL / EnvironmentFrontend may be pointing to different environment..🔍 How I debug:Open Browser DevTools → Network tab → compare request with Postman → identify difference → fix backend or frontend config..#fyp #tech #explore #viral #trending by @blackcask_
1k
5 months ago
Download
Day 6/365 Save and Follow @blackcask_ for more such content...This is a classic system design interview question - and it’s NOT about servers or databasesThe problem isn’t compute.It’s distanceWhen a user in Singapore opens your website and your servers are in the US, every request travels thousands of kilometers *ImagesCSSJavaScriptAll crossing oceansMore distance = more latencyAdding more backend servers in the US - NoOptimizing code - NoNeither fixes this problem.The correct answer is: use a CDNA CDN (Content Delivery Network) caches static content like images, videos, CSS, and JavaScript on servers distributed across the worldSo instead of an Singaporean user fetching content from theUS, they get it from a nearby edge location#viral #tech #java #code #indiansinsingapore by @blackcask_
845
7 months ago
Download
Answer :✅ Configuration Language:* Maven uses XML (pom.xml)* Gradle uses Groovy/Kotlin DSL (build.gradle)✅ Build Performance:* Maven builds are generally slower for large projects.* Gradle supports incremental builds and build caching, making it faster.✅ Flexibility:* Maven follows a strict convention and is less customizable.* Gradle is highly flexible and easier to customize.✅ Multi-Module Projects:* Maven supports multi-module projects.* Gradle handles large multi-module projects more efficiently.✅ Learning Curve:* Maven is easier for beginners.* Gradle has a steeper learning curve due to scripting capabilities.✅ Community & Adoption:* Maven is widely used in Selenium automation frameworks.* Gradle is heavily used in Android and large enterprise applications..Follow and save for future.#viral #tech #explore #fyp #trending by @blackcask_
0
3 days ago
Download
Ans:-✅ Command: git revert <commit-hash>✅ Purpose: Safely undo changes from a commit that is already pushed to a shared branch.✅ How it works: It creates a new commit that reverses the changes of the selected commit.✅ Why it is safe: It does not rewrite Git history, so other team members are not affected.ex- git revert xyz123Best practice: Use git revert for shared branches instead of git reset, as reset changes history and can cause conflicts for others..Follow and save for future interviews..#fyp #viral #explore #trending #tech by @blackcask_
2
4 days ago
Download
Ans:Why is this answer wrong?❌ left + right can cause integer overflow when both values are very largeleft = 2_000_000_000right = 2_100_000_000 So in above when u add result overflows and may become a negative number, causing Binary Search to fail….Correct Approach ✅mid = left + (right - left) / 2;Why does this work?* right - left is usually much smaller.* Prevents integer overflow.* Produces the same result as (left + right)/2.* This is the standard approach used in production code.——-Advanced Bitwise Approach :mid = (left & right) + ((left ^ right) >> 1);.Follow and save for future interviews..#fyp #viral #explore #trending #tech by @blackcask_
2
5 days ago
Download
Ans:L4 Load Balancer:* Works at Transport Layer (Layer 4).* Routes traffic based on IP Address and Port Number.* Does not inspect request content.* Faster and lower latency.* Best for TCP/UDP applications, databases, gaming servers.* Example: AWS NLB.L7 Load Balancer:* Works at Application Layer (Layer 7).* Routes traffic based on URL, Headers, Cookies, Hostname, etc.* Understands the actual HTTP request.* Slightly slower due to request inspection.* Best for Web Applications, APIs, Microservices.* Example: AWS ALB, NGINX.Quick Difference* L4 = IP + Port based routing (Fast)* L7 = Content aware routing like URL/Header based (Smart)Real-Time Example* L4: All requests on port 443 → Any healthy server.* L7: /payment → Payment Service, /user → User Service.Interview One-LinerL4 load balancer is “faster” because it routes using IP and Port, whereas L7 load balancer is “smarter” because it can route based on application data like URLs and headers..Follow and save for future interviews..#fyp #viral #trending #explore #tech by @blackcask_
0
6 days ago
Download
Answer :* Since services are distributed, a normal DB transaction (@Transactional) will not work.* Use Saga Pattern with compensating transactions.* Flow: 1. Order Created ✅ 2. Payment Deducted ✅ 3. Inventory Update Failed ❌ 4. Trigger rollback events: * Refund Payment * Cancel Order* This ensures eventual consistency across services.* Usually implemented using Kafka/RabbitMQ + Retry + DLQ.——-Intervw ansr-In distributed systems, I would use the Saga Pattern. If inventory update fails after payment deduction and order creation, compensating transactions are triggered to refund the payment and cancel the order. This provides eventual consistency across microservices..#fyp #viral #explore #trending #tech by @blackcask_
2
9 days ago
Download
Answer:✅ Never log passwords, tokens, or PII directly.Avoid logging:* Passwords* OTPs* JWT Tokens* Credit Card Numbers* CVV* API Keys* Aadhaar/SSN details* Bank Account Numbers✅ Mask sensitive fields before writing logs.Ex- *****76K✅ Disable excessive DEBUG logging in production.✅ Use filters/interceptors for automatic masking.✅ Encrypt logs and restrict access using RBAC.✅ Follow compliance standards like GDPR, PCI-DSS and HIPAA✅ In real projects, centralized logging tools like ELK and Splunk are used with masking policies..We use centralised logging with masked data..#fyp #viral #explore #trending #tech by @blackcask_
2
10 days ago
Download
Answer: int is a primitive data type, while Integer is a wrapper class (object).✅ int stores the actual numeric value directly, so it is faster and memory efficient.✅ Integer is required when working with Collections Framework because collections can store only objects.List<Integer> list = new ArrayList<>();✅ Integer can hold null values, whereas int cannot.✅ Frameworks like Hibernate, Spring, JPA, JSON libraries often require objects, so Integer is commonly used there.✅ Integer supports autoboxing and unboxing:Integer x = 10; // Autoboxingint y = x; // Unboxing.Preferred Usage:* Use int when performance is important and null is not needed.* Use Integer when working with collections, databases, APIs, or when a value can be null..Follow and save for more such content..#fyp #viral #trending #explore #tech by @blackcask_
4
11 days ago
Download
Answer:• Apps maintain a persistent WebSocket/TCP connection with the server.• When internet goes off, heartbeats (ping/pong) stop, so the server marks the user as offline.• Incoming messages/calls are stored in queues or databases instead of being lost.• Once internet comes back, the app automatically reconnects and sends its user/device authentication token.• Server recognizes the user, marks them online (usually in Redis/presence service).• Server then pushes all pending messages, notifications, and missed call events to the device.• Device sends ACK (acknowledgement) after receiving them, and the server removes them from pending storage..Short-✅ The server detects that the user is back online when the app re-establishes its WebSocket connection and authenticates again. It then fetches and delivers all pending messages stored while the user was offline..#fyp #viral #explore #trending #tech by @blackcask_
4
12 days ago
Download
Answer :1. Don’t rely only on IP-based rate limiting * IPs can be easily rotated using proxies, VPNs, or botnets.2. Implement User/Token based rate limiting * Rate limit per: * User ID * API Key * Device ID * Session ID * Account3. Use Behavioral Analysis * Detect abnormal patterns like: * Too many requests in seconds * Same payload repeatedly * Requests from different IPs but same fingerprint4. Device Fingerprinting * Track browser/device signatures instead of only IP addresses.5. Bot Detection * Integrate CAPTCHA, reCAPTCHA, or bot management solutions.6. Use WAF/CDN Protection * Services like Cloudflare, Akamai Technologies, or AWS Shield can automatically block suspicious traffic.7. Implement Progressive Throttling * Instead of immediate blocking: * Slow down responses * Add delays * Temporarily ban suspicious users.8. Monitor and Alert * Use logs, metrics, and tracing to detect attack spikes quickly..Day-11/31 follow and save for more such content..#fyp #viral #explore #trending #tech by @blackcask_
0
14 days ago
Download
×

Download all media on this page

Photos Videos
back to up