Painel de Notícias

Tecnologia

7045 posts · 26 feeds · tópicos e interesse por Jev

Filtros
dev.to

Why Industrial Edge Gateways Need Store-and-Forward

Why Industrial Edge Gateways Need Store-and-Forward Many teams still treat an industrial edge gateway as a simple protocol bridge: collect data from the field, forward it to the cloud, and relay commands back down when they arrive. If the link works while the network is healthy, the design looks good enough. That assumption usually breaks in real deployments. Industrial links are not just "online or offline." A gateway may face: intermittent 4G or private WAN instability broker reconnect storms after a short outage API throttling on the cloud side telemetry that keeps arriving from PLCs while upstream delivery is blocked commands that were accepted by the gateway but not yet confirmed by the platform delayed replay mixed with newly collected realtime data The core argument here: if an industrial gateway sits between stable field collection and unstable upstream delivery, it should not behave like a transparent forwarder. It should behave like a reliable delivery boundary. That means implementing store-and-forward with local persistence, ordering control, deduplication, replay recovery, acknowledgment tracking, and expiration policy. Without that layer, the platform does not merely receive delayed data — it loses the ability to explain whether a record is complete, duplicated, stale, or still pending confirmation. A network break interrupts more than transmission time. It breaks a chain of operational meaning: when the value was produced when the gateway received it whether the platform ever acknowledged it whether the record was already consumed downstream whether the replayed record should still affect alarms or reports If the gateway does not preserve that chain, recovery produces a pile of late data with no trustworthy context. The result is usually: reports polluted by late-arriving values treated as current state duplicate alarm evaluations after replay operations teams unable to tell whether a gap came from field collection failure or upstream delivery failure

Infra
Interesse
dev.to

Graph Traversal Patterns: BFS vs DFS with Cycle Detection in Directed and Undirected Graphs

Graph traversal is a foundational concept in computer science and software engineering. Whether you are building social network recommendation engines, routing packets across networks, or resolving complex module dependencies in a bundler, graphs are the underlying data structure. Mastering graph algorithms requires a deep understanding of two fundamental traversal strategies: Breadth-First Search (BFS) and Depth-First Search (DFS). In this technical deep-dive, we will explore adjacency list representations, examine how to traverse directed and undirected graphs, implement robust cycle detection strategies (including the 3-color White-Gray-Black algorithm), and use BFS to solve unweighted shortest path problems. Before traversing a graph, we must decide how to store it in memory. For sparse graphs, which are common in real-world applications, the adjacency list is the preferred representation due to its $O(V + E)$ space complexity (where $V$ is the number of vertices and $E$ is the number of edges). Below is an idiomatic implementation of an unweighted graph using an adjacency list in Python: from typing import Dict, List class Graph: def __init__(self, directed: bool = False): self.adj_list: Dict[int, List[int]] = {} self.directed = directed def add_vertex(self, vertex: int) -> None: if vertex not in self.adj_list: self.adj_list[vertex] = [] def add_edge(self, u: int, v: int) -> None: self.add_vertex(u) self.add_vertex(v) self.adj_list[u].append(v) if not self.directed: self.adj_list[v].append(u) DFS explores as deep as possible along each branch before backtracking. It relies heavily on a stack (either the system call stack via recursion or an explicit stack data structure) and a visited set to prevent infinite loops. In an undirected graph, a cycle exists if we encounter a visited vertex that is not the immediate parent of the current vertex. def has_cycle_undirected(graph: Dict[int, List[int]]) -> bool: visited = set() def dfs(node: int, parent: int) -> bool: vi

Dev
Interesse
dev.to

The Two-Phase Machine: Your LLM Request Is Two Jobs in a Trench Coat

Every API call you make to an LLM is secretly two jobs glued together. The first reads your entire prompt in one giant matrix multiply — compute-bound, GPUs at full throttle. The second dribbles out tokens one at a time, each step re-reading the entire conversation history from memory — memory-bandwidth-bound, the GPU mostly idling. Run them on the same GPU and each one sabotages the other. The industry's 2026 answer, reached independently by half a dozen labs: stop running them on the same GPU. Split prefill from decode, and throughput per GPU roughly doubles. Think of a restaurant. The kitchen (prefill) cooks the whole order at once — blazing, batch-friendly, ovens full. The delivery van (decode) carries one box per trip — the speed limit is how fast you can load the van, not how fast you can drive. Now imagine one vehicle that has to be both. The delivery schedule wrecks the cooking, and the cooking wrecks the delivery. That vehicle was every serving engine before ~2024. A short "hi" and a 10,000-token document were processed by the same GPU pool in the same batch, and one long request held the whole batch hostage — classic head-of-line blocking. The fix wasn't a bigger oven. It was two separate fleets. Modern serving stacks are built from a small set of structural moves. Here they are, cheapest insight first: The KV cache. During decode, the model doesn't recompute attention over your prompt — it caches the key/value vectors and reads them back each step. Your 8k-token prompt becomes 8k vectors of state that must be read from GPU memory every single token. Decode is a memory problem, not a math problem. This one fact explains almost everything downstream. PagedAttention (vLLM). Before it, the KV cache was allocated as one contiguous chunk per request — like parking each car in its own private lot. Internal fragmentation wasted up to 80% of VRAM. PagedAttention borrows the OS trick of virtual memory: fixed-size blocks, non-contiguous, shared across requests. Wast

IAInfraDev
Interesse
dev.to

Your agent's memory fails silently. CortHeXis 2.0 is the part that notices.

Your coding agent's memory does not fail loudly. It fails the way a slow leak does: the agent just knows a little less every week, and you blame the model. I've been running my company's products through Claude Code sessions for five months, with a memory of short markdown notes behind them — 417 notes today, about 440,000 words, every one written while actually shipping something. Over that time I kept a list of every way that memory broke. Not one of them raised an error. Today we're releasing CortHeXis 2.0, the engine that came out of that list. It's open source (Apache-2.0), it runs alone next to any agent that speaks MCP, and it's the same code that runs our own memory. This post is about the failures first, because they are the product. 1. The memory server vanished for nine days. A tool rewrote our project's .mcp.json to add a browser server, and dropped the memory server in the process. Every session kept working. None of them could search the memory. Agents started answering from an index file that had been truncated to fit the context window. It took nine days to notice — because nothing was wrong, things were just worse. 2. One colon broke recall for a note. A note whose description: contains an unquoted : is invalid YAML. The indexer skipped its header, the note lost its description, and with it the few words the search was matching on. It still existed. It was just never found again. 3. A ghost note. A session appended a fact with cat >> pricing_rules.md while the note was called pricing-rules.md. A new file appeared, with no header, carrying a corrected fact — while the old note kept the wrong one. Two truths, and the search happily returned the stale one. 4. A better model made recall worse. We switched embeddings from MiniLM to EmbeddingGemma and recall jumped on our bench. But the hook that injects notes at every message kept the score threshold I had tuned "by eye" for the old model. Measured afterwards: it was injecting the right note in 22 % of c

IADev
Interesse
dev.to

Week Notes: What the House Learned

Three things broke this week, and they broke the same way. One. A memory index grew past a hard delivery limit. Fifty characters over, and the overflow was not trimmed — it was dropped entirely, while every internal consistency check kept reporting that all was well. The checks were arithmetically correct and epistemically useless: they verified that the numbers agreed with each other, not that anything had arrived. Two. A weekly test had an impossible pass condition baked into its own definition, so it filed a red alarm every week while measuring a healthy result. Its reports went to a mailbox and were auto-archived after a day by a script that counted hours, not readers. Eleven reports, zero readings. Three. An unexplained commit appeared, signed with a name we read as an outside author. It was not an outsider. It was one of our own scheduled agents, inheriting the repository's configured identity. Every commit any agent here makes wears the same signature. We were hunting a stranger and found a defect in attribution. The shape is identical in all three. A measurement returned something true about itself and false about the world, and did so in a confident, well-formatted voice. Not one of them failed loudly. They all failed politely, which is much worse, because a polite failure gets filed instead of fixed. What I am taking into next week: ask each instrument what it cannot see, and never accept a number without the boundary of what it actually measured.

Dev
Interesse
dev.to

If You Can't Draw the Boundary, You Don't Have an Architecture

The boundary question ended my whiteboard round before it started. The interviewer asked where my system ended. I listed components. He said I had just described the whole company. He was right. Watch the 40-second version first: Q2: System Design Interviews Start With the Boundary Interviewers ask "where does your system end" because that is where the thinking lives. A list of components is a shopping list, not a design. Tradeoffs only exist at seams: the moment you say "auth is not mine, it is the identity provider, and this token contract is all that crosses the line," you have made a real architectural decision. The candidate who never draws the dashed box is really saying: I have opinions about everything and responsibility for nothing. Here is the uncomfortable part. Most candidates CAN name the technical boundaries. Auth, payments, the CDN. They say those words and feel done. But they never say the part that actually matters in a real company: who owns the other side of the line. The boundary that kills real projects is never technical. It is the team boundary. Your storefront shell ends where the platform team's design system begins. Your checkout flow ends where the payments team's webhook contract begins. Your "simple read" from another team's service ends the night they ship a breaking change and nobody told you. If you cannot name the owner on the other side of the line, you have not drawn a boundary. You have drawn a wish. Interviewers know this. When they ask about the boundary, they are listening for one thing: does this person know the difference between what they build and what they depend on? Seniors answer in owners and contracts. Juniors answer in boxes. Auth. Not yours. Name the provider. State exactly what crosses the line: tokens in, sessions out. Payments. Not yours. Name the vendor. State the contract: webhooks, idempotency keys, who retries. Data you do not own. Which reads come from other teams' services, and who gets paged when they break

Dev
Interesse
dev.to

SHA3-256 vs Keccak-256: the one-byte difference that breaks Ethereum hashes

If you've ever hashed something in Python with hashlib.sha3_256 and got a different result from Solidity's keccak256, nothing is wrong with your code. You're using two different functions that share almost everything. Keccak won NIST's hash competition in 2012. When NIST published the final standard, FIPS 202, in 2015, it changed the padding: SHA-3 appends the bits 01 before the usual 10*1 padding (so the first padding byte is 0x06), while the original Keccak used 0x01. Ethereum had already adopted Keccak, so it kept the original. One byte, completely different outputs: Input Keccak-256 (Ethereum) SHA3-256 (NIST) "" c5d24601...5d85a470 a7ffc6f8...80f8434a "abc" 4e03657a...a12d6c45 3a985da7...11431532 Quick check: if your empty-string hash starts with c5d24601, you have Keccak-256. If it starts with a7ffc6f8, you have SHA3-256. import hashlib hashlib.sha3_256(b"abc").hexdigest() # NIST SHA3-256 from Crypto.Hash import keccak # pip install pycryptodome k = keccak.new(digest_bits=256); k.update(b"abc"); k.hexdigest() # Ethereum import { createHash } from "node:crypto"; createHash("sha3-256").update("abc").digest("hex"); // NIST SHA3-256 import { keccak256, toUtf8Bytes } from "ethers"; keccak256(toUtf8Bytes("abc")); // Ethereum Watch out for library names: Solidity's old sha3() was an alias of keccak256(), and some packages still say "sha3" when they mean Keccak. I put every variant side by side in a free in-browser tool: sha3.si. Type transfer(address,uint256) and the first 8 hex characters of Keccak-256 give you the ERC-20 selector, a9059cbb. From the terminal: npx sha3-check -s "transfer(address,uint256)" -a keccak-256.

SegurançaDev
Interesse
dev.to

AI 週報 — 2026-10-02 to 2026-10-09 | 模型、商業與硬體三方同時加速

$0.10 / 百萬輸入 token、1.56 TB 開源權重、400 億美元籌資買 GPU、整合本機推論的 AI PC——四個數字同時落到一週之內。本期拉出三條線:小型模型與長脈絡的成本曲線被重新畫、算力供需的資金壓力來到本季新高、終端推論被 Microsoft 與 NVIDIA 重新押注。下游工程團隊要重新評估成本、部署邊界與供應商風險。 Anthropic 釋出 Claude Haiku 5.5,主打一百萬 token 脈絡與每百萬輸入 token 0.10 美元的定價Anthropic Releases Claude Haiku 5.5: A Small Model With 1M Context Priced at $0.10 per Million Input Tokens - MarkTechPostIntroducing Claude Haiku 5.5 on AWS | Artificial Intelligence - Amazon Web Services (AWS)。這個價位把小型模型類別的底線再次壓低;搭著一百萬脈絡一起賣,是這週值得工程團隊注意的組合。 成本面權衡:長脈絡不等於免費。一百萬 token 脈絡在注意力成本上仍是線性或更糟,多數長脈絡工作在 production 階段會被前置摘要或視窗切分拿掉,所以脈絡長度多半只在 RAG 摘要前處理、長程除錯紀錄審閱、整份程式碼庫問答這類場景有真實價值。對成本敏感的批次工作(ETL 轉換、報表分類、低風險客服分流),這條線已經達到可以拿來換掉中型模型的臨界點。 部署面替代方案:對極度延遲敏感或需要嚴格私有部署的場景,本機量化版本仍是起點——Haiku 5.5 的雲端便宜並沒有消滅 7B–13B 量化本機模型在邊緣設備的價值。本週討論模型 API 成本 vs 自架推論時,要先回答的問題是:這個工作能不能容忍單次呼叫兩百毫秒以上的延遲、能不能承受雲端往返的合規成本。如果兩個都否定,自架仍然存在。 來自廠商官方的說法必須標明歸屬:百萬脈絡與 0.10 美元定價是 Anthropic 與 AWS 的官方公告口徑Introducing Claude Haiku 5.5 on AWS | Artificial Intelligence - Amazon Web Services (AWS),並非獨立第三方基準複驗。採購決策應以自身評測結果與供應商 SLA 為準,別直接採用官方基準當唯一證據。 工程團隊的人才層訊號:Anthropic 在本期同步公布 Frontier Academy 計畫,投入一億美元訓練一萬名工程師Claude Frontier Academy: $100M to train 10,000 engineers - Anthropic。這是商業發展面的訊號,與本週模型定價屬於不同切面,但放在一起讀可以看出 Anthropic 正在「模型 + 生態」雙線投入。 Moonshot AI 在 Hugging Face 放上 1.56 TB 的 Kimi K3 權重供學術研究使用,並釋出架構細節Moonshot AI Releases Kimi K3 Architecture Details, 1.56 TB Model on Hugging Face - TechJuiceWhat is Kimi K3: Moonshot’s frontier AI model that matches Claude Opus 4.8 and GPT 5.5 - Digit。依官方說法,Kimi K3 被定位為與 Claude Opus 4.8 及 GPT 5.5 同級的 frontier 模型What is Kimi K3: Moonshot’s frontier AI model that matches Claude Opus 4.8 and GPT 5.5 - Digit——但這是廠商敘事,獨立重現是否一致仍待社群驗證。 工程含義:開源權重的真正價值在於架構透明度與可審計性,這對學術研究、重現性研究與安全對齊研究有實質幫助;對 production 部署而言,1.56 TB 的權重在多數企業硬體上是難以直接服務的,多數團隊會拿較小的開源模型做微調或蒸餾,而不是把 Kimi K3 原尺寸跑起來。Moonshot 釋出的意義多半在學術與研究社群,不在企業可商用部署。 SpaceX 籌資四百億美元採購 NVIDIA GPU 的消息分散在多個來源SpaceX Eyes $40 Billion Financing Deal for Nvidia AI Chips, Reports Say - Channel InsiderSpaceX Seeks $40 Billion

IA
Interesse
dev.to

MediaLive without timecode: what Video Aligned Locking changes in redundancy

Every redundant live-streaming design promises the same thing: if pipeline A dies, the player carries on with B and the viewer never notices. What almost nobody writes into the ADR is the condition for that promise to hold, both pipelines must be on the same frame, at the same instant, with the same segment boundaries. For years that required embedded timecode at the source, and timecode belongs to OB trucks, not to an SRT encoder in a stadium or an RTMP push leaving a small studio. Video Aligned Locking in AWS Elemental MediaLive, announced on September 12, 2026, removes that dependency: the encoder compares visual signatures of frames across pipelines and aligns on content. It is worth understanding what it solves, what it does not, and where it fails without telling you. A MediaLive STANDARD channel runs two pipelines in different Availability Zones. The upstream system sends the same signal to both inputs, MediaLive processes in parallel, and each output group delivers two copies, one per pipeline, to the downstream (MediaPackage, your own origin, a CDN). Redundancy lives in the downstream being able to pick either copy at any moment. What breaks: two independent encoders do not start on the same frame. Each receives the signal with its own jitter, starts encoding at its own instant, and cuts segments at its own points. Without synchronization, segment 1042 on pipeline 0 and segment 1042 on pipeline 1 contain different content, shifted by a few dozen frames. When the origin switches pipelines, the player sees a jump forward or a repeat. In sports, that is the goal the viewer watched twice. The historical answer: embedded timecode (SMPTE 12M, VITC, ancillary data). With timecode, both encoders know "this frame is 14:32:07:12" and cut at the same point. That is the SOURCE_TIMECODE method, MediaLive's default to this day. It works well in traditional broadcast, where the whole chain carries timecode from the camera onward. Where the historical answer stops: most di

Infra
Interesse
dev.to

Detection Engineering Starts With the Logs You Decided to Keep

Detection Engineering Starts With the Logs You Decided to Keep Detection content is written against telemetry. If the telemetry does not exist, the rule cannot be written, tested or tuned. The practical ordering is therefore log coverage first, detection second. Authentication outcomes, including failures and successes from remote access and identity providers, are the backbone of intrusion detection. Account changes, such as new administrative roles, new credentials and modified federation settings, describe the persistence stage. A log is only usable if it identifies the actor, the action, the target and the result, and if those fields can be joined to the same identity across systems. Timestamps must be consistent and timezone-aware, or events will be ordered incorrectly during an investigation. Alert volume is the reason detection programmes stall. The fix is not to disable rules but to add context: enrich alerts with asset criticality and identity privilege, then route the high-context ones to responders and aggregate the rest. NIST SP 800-92, Guide to Computer Security Log Management: https://csrc.nist.gov/pubs/sp/800/92/final Microsoft Learn, Security and governance for DevOps: https://learn.microsoft.com/en-us/security/benchmark/azure/mcsb-v2-logging-threat-detection MITRE ATT&CK knowledge base: https://attack.mitre.org/

Segurança
Interesse
dev.to

Security Audit Report: Reentrancy & Access Control Review: Venus Core Pool

Security Audit Report: Reentrancy & Access Control Review: Venus Core Pool Target Protocol: Venus Core Pool (TVL: $1295.9M) Security Audit Report – Reentrancy & Access‑Control Review Protocol: Venus Core Pool (Ethereum & L2) – TVL ≈ $1.30 B Audit Window: 2024‑10‑01 → 2024‑10‑07 Prepared by: Senior DeFi Security Researcher – XYZ Audits Date: 2024‑10‑08 The Venus Core Pool is the backbone liquidity‑pool contract suite that underpins the Venus ecosystem on Ethereum and its L2 roll‑ups. Its primary responsibilities are: Accepting deposits of supported ERC‑20 assets. Minting vTokens (interest‑bearing representations). Distributing accrued interest and handling withdrawals. Coordinating with the Comptroller for market entry/exit, collateral factor updates, and liquidation logic. Our focused review examined reentrancy safety and access‑control hygiene across the core contracts (VToken.sol, Comptroller.sol, InterestRateModel.sol, Timelock.sol, AdminProxy.sol, and related libraries). The codebase largely follows the patterns introduced by Compound and has been hardened over multiple releases, but several critical and high‑severity issues were identified that could enable an attacker to: Steal user funds via a re‑entrancy loop on the withdraw/redeemUnderlying path when a malicious token implements a crafted transfer callback. Escalate privileges by exploiting missing onlyAdmin checks on configuration functions in the Comptroller and on the upgrade‑proxy admin. Bypass timelock constraints through a race condition in the Timelock.executeTransaction logic that can be triggered by a malicious proposer. Overall, the contract suite receives a Risk Score of 7 / 10 (High). The majority of the risk stems from the combination of re‑entrancy‑prone external calls and inadequate role separation for critical governance functions. # Vector Affected Component(s) Description Impact Likelihood 1 Re‑entrancy on redeemUnderlying / withdraw VToken.sol – redeemUnderlying(), redeem(), borrow() The

SegurançaDev
Interesse
dev.to

The AI That Never Leaves My Laptop

Show almost any enterprise a useful AI workflow and the demo goes well right up until someone from security asks the only question that matters: where does the data go? For every mainstream assistant the answer is some version of "to a datacentre we operate, under a policy you should read." For a lot of teams that's fine. For the ones I work with — regulated industries, client-confidential material, an internal audit function with opinions — it ends the conversation. Not because the tool is bad, but because the paperwork to say yes costs more than the productivity it buys. So I built the other thing. OnDevice.ai is a private AI workspace that runs on my own machine: streaming chat, project-based context, file analysis, and real PowerPoint, Excel and Word generation. Inference runs locally through Ollama or LM Studio. Cloud is an option, not an assumption. Running a 30B model locally on a MacBook. Backend: Ollama · Model: Glimmer 30B (GGUF). There's an obvious way to make an AI produce a PowerPoint file: ask the model for one. It's also a bad way. OOXML is a zip of interdependent XML parts with relationship graphs and content-type manifests, and a single malformed relationship gives you a file that refuses to open — usually when your client double-clicks it. So the model never touches the bytes: The model produces a JSON intermediate spec (SlideDeckSpec, WorkbookSpec, DocumentSpec), which is schema-validated first. A fixed, deterministic generator built on python-pptx, openpyxl or python-docx turns the spec into the file. Structural validation is a hard gate on download — zip, OOXML parts, relationship graph, well-formed XML. Fail, and the file is never offered. LibreOffice render checks run too, but only as advisory, in an isolated process on temp copies. LLMs handle conversation, analysis and planning language. Generators own bytes. The payoff: a file that downloads is a file that opens. Not "usually." Next.js + TypeScript at the front, FastAPI + Python behind it,

IADev
Interesse
dev.to

Debian 13 ZFS on ROOT Installer

Two installers for Debian 13 (Trixie) with root on encrypted ZFS, each with a different upstream guide: Script Bootloader /boot Upstream guide debian13-zbm-install.sh rEFInd → ZFSBootMenu on the ZFS root dataset ZFSBootMenu — Debian (UEFI) debian13-zbm-install-testing.sh rEFInd → ZFSBootMenu on the ZFS root dataset ZFSBootMenu — Debian (UEFI) debian13-root-on-zfs-grub.sh GRUB separate ext4 partition OpenZFS — Debian Trixie Root on ZFS Both scripts: use ZFS native encryption (aes-256-gcm, passphrase) — mandatory, not optional require the disk to be given as a stable /dev/disk/by-id/… path build the same dataset hierarchy with separate datasets for /home, /root, /opt, /srv, /var/log, /var/spool, /var/tmp and the container/VM stores create a default and a baseline boot environment install a 1 GiB encrypted swap partition with a fresh random key each boot install KDE, GNOME, or nothing, selected by an environment variable install CPU microcode and a broad firmware set (including firmware-iwlwifi) leave boot messages visible — quiet is not set anywhere Every step is tagged in the source with [GUIDE] (straight from the upstream document) or [DEVIATION] (with the reason inline), so you can audit either script against its guide. Introduction Requirements Quick start Disk layouts Dataset hierarchy Environment variables What happens at boot After installation Upgrading OpenZFS and the pool Recovery Deviations from the upstream guides Safety notes Credits License debian13-zbm-install.sh — ZFSBootMenu ZFSBootMenu is a small Linux+initramfs bundled into a single EFI executable. It imports your pool, asks for the passphrase, lists every boot environment and snapshot it can find, and kexecs into the one you choose. Choose it if you want boot environments to be a first-class, interactive feature: rolling back a bad upgrade is a menu selection at boot, not a rescue USB. You also get a snapshot browser, a diff viewer, a recovery shell, and pool health reporting before the OS ever sta

LinuxDev
Interesse
dev.to

Centralizing Webhooks Across Products: Why and How

Billing signs with one header, accounts sends a static token, bookings never retries. If several of your products send webhooks, this is probably familiar. Here's why consolidating them into one delivery system pays off, when it doesn't, and how to migrate. If several of your products send webhooks, running delivery through one shared system costs less to build, less to operate and less for your receivers. You build signing, retries, delivery logs, failure alerts and SSRF protection once and every product uses them, and your customers get the same format no matter which product sent the event. This post covers what happens when each product builds its own, the reasons to centralize and public examples, when centralizing isn't worth it, the weak points of a shared system and how to handle them, choosing between an in-house platform and a service, and the migration steps. All sources were checked on 2026-09-30. In short, you end up with the same components built slightly differently once per product, and both receivers and on-call engineers have to learn every variation. A typical picture: billing signs with HMAC in an X-Signature header and retries three times, accounts sends a static token and no signature, bookings doesn't retry at all. Each works on its own, but the differences add up. Area Built per product Centralized Signing Header name, signed string and encoding differ per product One format (for example Standard Webhooks) Retries Counts, intervals and success criteria vary One schedule and one definition of success Deduplication IDs missing or named differently Every event has an ID that doesn't change across retries Delivery logs Search each product's logs separately Search every product in one place Failure alerts Some products alert, to different places Same conditions, known destinations SSRF protection Each implementation can miss a case Checked in one place Secret rotation Different procedure per product One procedure and one overlap period Receiver do

Dev
Interesse
dev.to

Android System Design: A Practical Guide for Senior Android Engineers

Learn how to design production-ready Android systems with scalable architecture, offline-first data, networking, synchronization, security, performance, and real-world examples. Modern Android development is no longer only about building screens and connecting APIs. As an Android application grows, engineers need to think about: Scalability Reliability Offline support Data synchronization Networking Caching Security Performance Background processing Real-time communication Modularization Maintainability A production Android system is a combination of the mobile client, backend services, data stores, networking layer, and operational infrastructure. This article explains how to approach Android system design from a senior mobile engineer's perspective. Mobile system design is the process of designing the complete architecture of a mobile system and understanding how its components communicate. A simplified production architecture looks like this: Android Application | ------------------------------------------------- | | | Compose UI Local Storage Network | | | ViewModel Room Retrofit | | | UseCase | API Gateway | | | Repository ------------- | ------------------------- | | | ------------------------- | | | | | Auth Chat Media | Service Service Service | | | | | | Redis CDN | | | | | Database | | ---------------------- Backend ----------------------------- The important idea is that Android is one part of the overall system. System design generally involves two important levels. SYSTEM DESIGN | -------------------------- | | HLD LLD | | High-Level Design Low-Level Design | | Components Classes Services Interfaces APIs Methods Databases Models Cache Patterns Communication Concurrency Scalability Error handling HLD answers: What are the major components and how do they communicate? Example: Android App | +---- REST API ------> API Gateway | +---- WebSocket -----> Chat Service | -------------------- | | | Redis Database Queue At HLD level, focus on: System components Da

MobileDev
Interesse
dev.to

Customer Support Duplicate Alerts: Idempotency Keys Across Polling Errors and Retries

Duplicate alerts in a customer-support AI agent loop usually come from polling the same errors plus sender retries, not from six distinct failures. The fix is idempotency: use a stable dedupe key and cooldown around each condition before a webhook, email, or SMS sender runs. TL;DR: Put a small incident state machine between the query and the sender. Derive a stable key from the error group or metric condition, record the notification before sending, enforce a cooldown, and require consecutive healthy polls before resolving. Enrich one incident from recent events instead of notifying once per event. This favors signal quality over notification volume and makes transport retries boring. A poller observes state, but a notification describes a transition. Confusing those two jobs is the root mistake. Suppose the support agent's model step fails at 09:00. A one-minute poll sees the same open error at 09:00, 09:01, and 09:02. Meanwhile, the 09:01 worker loses its acknowledgement after sending and runs again. A stateless implementation can emit four messages for one continuing incident. That is noise. The tempting first design is an alerted Boolean. It fails as soon as a resolved condition returns, because the bit cannot distinguish an old incident from a new one. A timestamp alone also fails: it rate-limits messages but does not model recovery. The explicit trade-off is a little more durable state in exchange for knowing whether a poll means open, update, renotify, or resolve. For a support queue, I would rather explain those four transitions than ask an agent team to infer incident boundaries from twenty near-identical messages. The dedupe key should represent the condition an operator can act on, such as tenant + agent_stage + error_group, rather than a raw event ID. A metric threshold needs the same treatment: key the threshold condition, not each sample. Keep the event count, latest timestamp, and a few recent examples as enrichment on that incident. The on-call perso

Dev
Interesse
dev.to

Every Boundary Has a Cost

What separation buys us, and what the running system pays for it. Something I keep noticing in software discussions is how easily we talk about boundaries as if they were inherently beneficial. Separate the responsibilities. Decouple the components. Extract the service. Put a queue between them. Give each domain its own database. The direction is almost always toward more separation, and the separation itself is often presented as evidence that the system is becoming better designed. But a boundary can change the physical constraints of the problem. Work that once happened inside a process can now require data to move between machines. We introduce latency, communication overhead, and coordination requirements into the same business operation. And depending on where we put that boundary, those changes can be surprisingly expensive. In my previous post, I wrote about the distinction between physics, engineering, and architecture, and how I think the industry often approaches them in the wrong order. Architecture becomes the starting point, while the underlying constraints become something we discover later, usually when the system is already difficult to change. I think the way we discuss boundaries is one of the clearest examples of that inversion. Because on a diagram, a boundary is almost free. You draw another box, move a responsibility into it, and connect it to the rest of the system with an arrow. The diagram becomes more organized. The responsibilities become more explicit. Everything looks a little more intentional. But in the running system, that arrow has to become something. Sometimes it becomes a function call. Sometimes it becomes a network request. Sometimes it becomes a message that sits in a queue until another process is available to handle it. Those are very different mechanisms, with very different costs, even when the diagrams look almost identical. And I think we often spend much more time discussing the boxes than understanding what we have pla

Dev
Interesse
dev.to

Where Muse Spark Code is going: bring your own models, agent teams and every editor

Muse Spark Code is a free, open source coding agent for Meta's Muse Spark. I've been building it in public, and a lot of people have asked the same question: where is it going? This is the answer, along with a quick tour of what it already does. One agent, every editor. Muse Spark Code runs as an ACP agent in Zed, JetBrains IDEs, Neovim and Emacs, and as an extension for Cursor, Windsurf, VSCodium and VS Code. It works with your Muse subscription through the Muse Code CLI, or with a Meta Model API key. A few things make it different from a plain chat panel: Subagents you can watch. When work is delegated, every subagent shows up on a live agent map with its role, status, token use and its own transcript, so you can follow and steer it. It checks its own web changes. The agent can open your local dev server in an isolated headless browser, click and type, and read console errors and failed requests before it tells you it's done. Hardware, too. A bundled Muse Gadgets skill builds, flashes and monitors ESP32 boards. Questions don't block you. When the agent needs your input, the question waits in a card while you keep working. You can answer later, or explain what you want instead. No telemetry. It's MIT licensed, has no hosted server of its own, ships in 15 languages and is checked against WCAG 2.2 AA. These are roughly in order. There are no dates; each one ships when it's ready. Save and share prompts and chats. A personal prompt library you can use in any project, with right-click Save on your own messages and prompts with variables. Chats export as Markdown, HTML or JSON, with an exact preview and redactions highlighted. Bring your own models. OpenAI, Anthropic and Google Gemini keys, local models, and ChatGPT and GitHub Copilot sign-in, alongside Muse Spark. Each feature turns on only for models that support it. Agent teams. Research, design, engineering, QA, code review, docs and marketing roles, each with its own caps, orchestrated by the main agent. A usage an

IADev
Interesse
dev.to

Strangling Procedural Legacy PHP into Laravel

The big bang rewrite is the most confident decision an engineering team can make and one of the worst. The pitch is always reasonable. The current system is slow to change, everybody agrees it is slow to change, so we pause feature work, rebuild it properly, and come back in six months with something maintainable. What actually happens is that month four arrives, the business needs a feature the old system can still deliver and the new one cannot, and the rewrite is either shipped half finished or quietly abandoned. Now you have two systems to maintain instead of one. That risk goes up when the thing you are replacing is not on an older framework. Migrating Symfony 2 to Laravel is unpleasant but legible. There are controllers, there is routing, there is a service container, and you can map concepts across. A procedural monolith gives you none of that. You get global state read straight out of $_GET and $_POST, mysqli_query calls interleaved with HTML, header('Location: ...') scattered through business logic, and includes that pull in half the application as a side effect. There is no seam to grab hold of, which is exactly why people conclude the only option is to start again. There is another option. Put Laravel in front of the old application, migrate one route at a time, and let the procedural code carry on serving everything you have not reached yet. This is the strangler fig pattern, named after the vine that grows around a host tree, gradually takes over its structural role, and leaves a hollow shell behind. The important detail is that at no point during that process is the tree unable to stand. The first move is deciding who owns the incoming request. It has to be Laravel, and it has to be Laravel from day one, even when Laravel is handling exactly zero routes. The web server serves Laravel's public directory as the document root. Anything Laravel does not recognise falls through to the legacy entry point. As you migrate an endpoint, it stops falling through,

Dev
Interesse
dev.to

⁧دعم العربية (RTL) في Next.js 16 — ٦ أخطاء شائعة وكيف تتجنبها⁩

،السلام عليكم ⁧معظم تطبيقات SaaS تُبنى بالإنجليزية أولًا، ثم تُضاف العربية في النهاية… فينهار كل شيء: الهوامش في الجهة الخاطئة، الأيقونات معكوسة، التواريخ غير مفهومة.⁩ ⁧أثناء بناء قالب SaaS بـ Next.js 16 الداعم ل عشر ١٠ لغات منها العربية، واجهت هذه المشاكل واحدة تلو الأخرى. إليك الحلول التي اعتمدتها.⁩ ⁧1. ضبط dir و lang على مستوى ⁩ ⁧لا تضع dir="rtl" على عناصر متفرقة. اضبطه مرة واحدة في الـ layout حسب اللغة:⁩ // app/[locale]/layout.tsx const RTL_LOCALES = new Set(['ar', 'he', 'fa', 'ur']); export default async function LocaleLayout({ children, params, }: { children: React.ReactNode; params: Promise ; }) { const { locale } = await params; const dir = RTL_LOCALES.has(locale) ? 'rtl' : 'ltr'; return ( {children} ); } ⁧خاصية lang مهمة أيضًا: قارئات الشاشة تعتمد عليها لنطق النص بشكل صحيح.⁩ left و right⁩ ⁧الخطأ الأكثر شيوعًا هو ml-4 أو pr-2 أو left-0. استخدم الخصائص المنطقية (logical properties) التي تنقلب تلقائيًا:⁩ ⁧استخدم⁩ ⁧بدلًا من⁩ ms-4 / me-4 ml-4 / mr-4 ps-2 / pe-2 pl-2 / pr-2 start-0 / end-0 left-0 / right-0 text-start text-left rounded-s-lg rounded-l-lg border-s border-l ⁧وفي CSS العادي: margin-inline-start بدلًا من margin-left.⁩ ⁧أسهم "التالي" و"السابق" يجب أن تنعكس. أما أيقونات مثل البحث أو الإعدادات أو علامة ✓ فلا:⁩ Intl⁩ ⁧لا تكتب التنسيق يدويًا. واجعل نظام الأرقام قرارًا واعيًا: في تونس والجزائر تُستخدم الأرقام اللاتينية (123)، وفي المشرق ومصر وفلسطين غالبًا الأرقام الهندية (١٢٣).⁩ new Intl.NumberFormat('ar-TN', { style: 'currency', currency: 'EUR', }).format(29.99); new Intl.DateTimeFormat('ar', { dateStyle: 'long', numberingSystem: 'latn', }).format(new Date()); ⁧الخطوط اللاتينية لا تحتوي غالبًا على حروف عربية، فيستخدم المتصفح خطًا احتياطيًا رديئًا. حمّل خطًا عربيًا عبر next/font:⁩ import { IBM_Plex_Sans_Arabic } from 'next/font/google'; const arabic = IBM_Plex_Sans_Arabic({ subsets: ['arabic'], weight: ['400', '600'], }); ⁧ونصيحة: زد line-height قليلًا للعربية، فالحروف تحتاج مساحة أكبر عموديًا.⁩ ⁧أسماء المستخدمين، البريد الإلكتروني، أسماء المنتجات… قد تظهر

Dev
Interesse
dev.to

CVE-2026-88772: a DTLS memory overflow in Citrix NetScaler ADC and Gateway is being exploited now

CVE-2026-88772: a DTLS memory overflow in Citrix NetScaler ADC and Gateway is being exploited now Citrix published security bulletin CTX697096 on 27 September 2026 covering eight vulnerabilities in CVE-2026-88772 is a memory overflow in NetScaler ADC and NetScaler Gateway rated 9.5 under CVSS v4 by What is publicly documented for CVE-2026-88772 is deliberately thin, and that matters when planning NetScaler ADC and Gateway sit at the edge of the network. They terminate VPN sessions, publish internal The vulnerable branches are NetScaler ADC and NetScaler Gateway 14.1 before 14.1-73.37, NetScaler ADC A ZoomEye probe of app="Citrix NetScaler" matched 239,201 internet-facing assets. The CVE-indexed filter vul.cve="CVE-2026-88772" returned zero at the time of the query, which is expected for a disclosure this recent and says nothing about real-world exposure. Product-fingerprint counts describe devices that match the Citrix NetScaler fingerprint; they are not a count of confirmed-vulnerable instances. Apply the fixed builds listed by Citrix and repeated in the national advisories: NCSC-NL advisory NCSC-2026-0394: https://advisories.ncsc.nl/2026/ncsc-2026-0394.html CERT-FR alert CERTFR-2026-ALE-011: https://www.cert.ssi.gouv.fr/alerte/CERTFR-2026-ALE-011/ CERT-FR advisory CERTFR-2026-AVI-1235: https://www.cert.ssi.gouv.fr/avis/CERTFR-2026-AVI-1235/ Citrix bulletin CTX697096: https://support.citrix.com/support-home/kbsearch/article?articleNumber=CTX697096

SegurançaInfra
Interesse
dev.to

Model selection is an architecture decision

Stop Asking “Which LLM Is Best?” – Ask Which Model Fits This Workload Last quarter I was elbow‑deep in a fintech product that had to turn noisy bank statements into clean expense reports. My first instinct was to grab the “biggest” LLM, fire‑off GPT‑4, Claude‑2, Gemini‑1.5 and hope it would magically understand every column, currency and weird abbreviation. After a weekend of latency checks, cost tallies and exploding error logs I realized the “best” model on every public leaderboard still missed our real KPI: cost per successful parsing. The fix was to stop treating LLMs like shiny toys and start treating them as replaceable services. I listed the dimensions that actually mattered: capability (financial jargon, tables) reasoning (multi‑step extraction without hallucination) latency (<300 ms for a smooth UI) context length (statements can be 10 k tokens) modality (sometimes we get a PDF image, so OCR + generation matters) cost (every API call eats our margin) Then I built a tiny benchmark that mirrors the exact workflow: feed a real statement, ask for JSON line items, measure success (JSON parses, totals match). I ran it against three services: OpenAI gpt‑3.5‑turbo‑16k, AWS Bedrock Claude‑3 Opus, and Google Gemini‑1.5‑Flash. Model Accuracy Cost / 1k‑tok Latency gpt‑3.5‑turbo 92 % $0.012 420 ms Claude‑3 Opus 95 % $0.018 280 ms Gemini‑Flash 88 % $0.006 150 ms Cost‑per‑successful‑task = (cost per call) ÷ (success rate). GPT‑3.5: $0.013 Claude‑Opus: $0.019 Gemini‑Flash: $0.007 Suddenly Gemini‑Flash became the clear winner for our budget‑tight pipeline, even though its raw accuracy looked lower on paper. The trick is to version‑track the exact model you use (e.g., gpt-3.5-turbo-0613) and re‑run the benchmark whenever a new upgrade lands. In a later ed‑tech project I swapped Claude‑2 for Claude‑3‑Sonnet after a single test showed a 30 % latency drop and a 5 % reasoning bump, shaving $0.003 per student quiz from the cost‑per‑task metric. So the next time someone asks “Whic

IADev
Interesse
dev.to

Build a 100-line checker that catches chained-skill approval hijacks

Two agent skills, each harmless when read on its own, can get an agent to upload a report the user never agreed to share. The trick is a progress file. The first skill writes it; the second one trusts it. This post builds a small stdlib Python checker that shows the pattern and shows where a per-skill check goes blind. It is a teaching toy. Run it, change the scenarios, and see what breaks. The paper behind this is "Chaining Skills to Hijack LLM Agents" (Dong et al., arXiv:2610.01564, 1 October 2026). Their method, APEX, has an upstream skill that gets the agent to write an honest record of task progress with one false line in it: the user approved the next step. A downstream skill reads that record and acts on it. Across four action families and six models on SkillsBench, chains induced the attacker's chosen action in 512 of 690 attempts (74.2%). On GPT-5.4, the chain worked 84.3% of the time, and the same workflow merged into one skill worked 17.4% of the time. Splitting the payload across skills is what makes it work. It runs two rules over each scenario: Per-skill rule. Flag a skill if it contains a state-changing action (upload, send, delete, transfer) and an approval claim or override phrase in the same text. This is roughly how a one-file-at-a-time scanner thinks. Chain rule. Build a write/read graph across the installed skills. Flag any path where skill A writes file F with an approval claim, and a different skill B reads F and takes a state-changing action. There are five scenarios: the APEX-style chain, the same workflow merged into one skill, a chain with the approval claim reworded, and two benign pairs (tests then notify, lint then summarise). The benign pairs matter. A chain rule that flags every read-after-write is useless, since that is how half of all real workflows look. Save as chain_check.py. Python 3.8+, no dependencies. # Each scenario: (name, is_malicious, [(skill_name, skill_text), ...]) The two rules catch different scenarios. The per-skill

IADevSegurança
Interesse
dev.to

My refund handler checked the ledger before paying. It still paid twice.

A refund handler commits the refund, then loses its reply. Maybe the HTTP response timed out. Maybe the worker died before it acknowledged the queue message. Maybe it was an AI agent's tool call, and the agent saw a timeout and called the tool again with the same arguments. The sender did nothing wrong by retrying. The question is what your handler does with the second delivery. The usual fix is to look first: if the ledger already has a refund for this order, return early. I wanted to see how far that fix goes, so I wrote a small pytest plugin that delivers the same event again in four different ways and counts how many times the effect landed. It is public and runs offline: github.com/jigonyoo/replay-twice. Scenario What happens duplicate the same event arrives twice, one after the other timeout_retry the handler finishes, its reply is replaced by a timeout, and a scripted agent retries the same tool call with the same arguments crash_before_ack the handler finishes, the acknowledgement is lost, and the event is redelivered: the queue's or webhook sender's view (the lost ack is simulated with an exception; no process is killed) concurrent eight deliveries at once: threads released together by a barrier, or eight tasks on one event loop for async def handlers The verdict does not come from the handler's return value. You give the drill an effects(key) function that counts what was actually committed, such as rows in the refund ledger for that order, and a trial passes only if the count is exactly one. The repository ships SQLite versions of a refund tool and a payment.succeeded webhook, each written four ways: naive writes the refund every time. check_then_act reads the ledger, and writes only if nothing is there. guarded_raises claims the order id in a table with a unique key, in the same transaction as the refund. A second claim raises an integrity error. guarded makes the same claim with INSERT OR IGNORE and returns “already applied” when the claim was already t

Dev
Interesse
dev.to

Go Web Frameworks in 2026: net/http, chi, Gin, Echo, Fiber Compared

Go ships a production-capable HTTP server in its standard library, and since Go 1.22 the built-in router handles method matching and path parameters on its own. The framework question has narrowed, not disappeared. Five stacks cover almost every Go backend decision in 2026: the standard library's net/http, chi, Gin, Echo, and Fiber. Each takes a different position on the same tradeoff — what the library gives you versus what you owe it in dependencies, conventions, and ecosystem compatibility. This article compares them on routing power, handler ergonomics, middleware, and measured performance, then ends with a decision table rather than a single verdict. If you are starting from zero and want the full build process around your choice — validation, authentication, testing, deployment — the step-by-step version lives in Building REST APIs in Go. Here the focus stays on the stacks themselves. The reason the framework debate changed shape is one addition to the standard library. Go 1.22 gave http.ServeMux method-aware patterns and path parameters: mux := http.NewServeMux() mux.HandleFunc("GET /users/{id}", func(w http.ResponseWriter, r *http.Request) { id := r.PathValue("id") // ... }) mux.HandleFunc("POST /users", createUser) Before this, any API needing GET /users/{id} required a third-party router, which is how Gin, chi, and Echo became defaults. In 2026, the stdlib covers static routes, method matching, single-segment and wildcard parameters, and middleware via plain function wrapping. What it still does not give you: route groups, composable middleware chains, struct binding, or per-route param types. net/http (stdlib) chi v5.3.2 Gin v1.12.0 Echo v4.16.0 Fiber v2.52.15 HTTP engine net/http net/http net/http net/http fasthttp Handler signature func(w, r) func(w, r) func(c *gin.Context) func(c echo.Context) error func(c *fiber.Ctx) error http.Handler compatible yes yes yes yes no Middleware ecosystem growing, stdlib-shaped stdlib-shaped largest, Gin-specific large,

Dev
Interesse
dev.to

Rate-Limited Reminder Recovery: Idempotent Queues After Webhook and Email Send Failures

Short answer: put each user reminder on a queue, make the consumer idempotent, retry transient delivery failures with backoff, and move exhausted work to a dead-letter queue (DLQ) for deliberate redrive. For a rate-limited e-commerce worker pool, the best queue is the one whose recovery controls your team can operate at 02:00, not the one with the longest feature list. This choice starts with an evaluation constraint: a checkout follow-up may be delivered once, but it must never be intentionally sent twice just because a worker lost its lease. Email and webhook providers can time out or return HTTP 429. Queue delivery is at-least-once, so the awkward case is a worker that sends successfully and crashes before acknowledging the message. Retries are expected. Duplicate side effects aren't. The simple approach is to schedule a callback and call the provider directly. It looks fine in a notebook. In production, however, that design mixes timing, provider rate limits, retries, and recovery in one process. A queue between scheduling and delivery gives each concern a visible boundary: producers describe intent, workers spend the provider's rate budget, and operators inspect poison messages without stopping healthy reminders. Classify outcomes before choosing retry numbers. A timeout or HTTP 429 is usually a retry candidate; malformed destination data is not made healthier by ten identical attempts. Honor Retry-After when it is present, otherwise use exponential backoff with jitter. Keep the attempt count and the next eligible time with the job so a restarted worker doesn't forget where it was. A dead-letter queue is part of that state machine, not a graveyard. When attempts are exhausted, record enough context to answer three questions: which reminder failed, which destination was involved, and which error class made it terminal. Redrive only after the underlying cause or data has changed. Blind redrive can recreate the same rate spike that caused the backlog. Keep payload

DevInfra
Interesse
dev.to

Node.js Realtime Backpressure Contracts for Shared Kanban Board Tests

Short answer: keep the board's event log authoritative, apply backpressure at the connection boundary, and test state convergence instead of hoping wall-clock sleeps line up. For a healthtech chat room or shared kanban board, presence accuracy is the decision axis: a delayed cursor is annoying, but a stale "online" clinician can misroute work. The useful contract is small. Every mutation gets an ordered sequence, every reconnect asks for a cursor, and presence is explicitly soft state with a lease. A test should control delivery and acknowledgements with a virtual clock. Three seconds is a policy value, not a timing oracle. Start with invariants, because throughput numbers hide correctness failures: A card transition is applied once per sequence number, even after a reconnect. A client that falls behind is told to resume from a cursor or fetch a snapshot; it is never silently given a partial stream. Presence expires when its lease expires, not when an arbitrary test sleep happens to finish. A slow consumer cannot make the server retain unbounded events for every room. The WebRTC recommendation describes connection and transport behavior, but it does not define your board's ordering or presence policy. Those belong in your application protocol. WebSocket or WebRTC can carry the bytes; neither one decides whether card-17 moved before card-22. One sentence matters here. Presence should be modeled as a lease: expires_at = last_heartbeat + lease, with the server clock as the authority. The UI may display "reconnecting" while a lease is still valid, but it must not manufacture an online member after expiry. I'm not sure a five-second lease is right for your network and clinical workflow; measure reconnect distributions, then choose it deliberately. The critical path has four boundaries. The command handler validates a mutation and appends it to durable room storage. A fan-out worker reads the append-only sequence and offers it to each connection. The connection has a boun

Dev
Interesse
dev.to

14 Tools, Zero Servers: How I Built a Whole Utility Belt That Runs 100% in Your Browser

This is part 2 of my browser-local tools series. In part 1 I argued that your files don't need to leave the device. This time, the full tour: 14 utilities I shipped that run 100% in the browser — each with the 30-second "how it actually works" for fellow devs. If you code, steal these patterns. If you don't, just bookmark the tools. The whole collection lives at Quick Toolbox — free, no sign-up, and every tool works offline after the first load. Here's what's inside. Image Compressor — Shrink JPG/PNG/WebP photos before sending them anywhere. Under the hood it's three lines of real work: createImageBitmap(file) to decode, drawImage() onto a canvas at the target size, then canvas.toBlob(callback, 'image/jpeg', quality) where the quality slider maps straight to that third argument. A 4MB phone photo becomes ~300KB at quality 0.8 with no visible difference. Image Converter — Same pipeline, different MIME type. JPG ↔ PNG ↔ WebP, which covers 99% of real-world needs. The trick most people miss: converting PNG screenshots to WebP typically cuts 60–80% of the bytes. Image Resizer — Set exact pixel dimensions or scale by percentage, with aspect-ratio lock so nothing gets stretched. Also lets you switch output format in the same pass — resize and convert in one click. PDF Merger and PDF Splitter — The flow: FileReader → ArrayBuffer → a PDF library running in the page → copyPages() into a new document → save → trigger download. No server ever sees the bytes. This is the one I care about most: contracts, ID scans, bank statements — the exact documents you should never upload to a random "free PDF tool" site. JSON Formatter & Validator — JSON.parse() in a try/catch; on failure it maps the character offset from the error message back to a line and column so you see exactly where the trailing comma is. Beautify, minify, one click each. Base64 Encode & Decode — The classic pitfall: btoa() throws on anything outside Latin-1. The fix is TextEncoder → bytes → btoa(String.fromCharCode(

Dev
Interesse
dev.to

S3 Vectors Now Filters Before It Searches: Metadata Pre-Filtering for Multi-Tenant RAG

If you run RAG on Amazon S3 Vectors with metadata filters, you may have been losing results without knowing it. Ask for the 10 nearest chunks for one tenant and you might get 3 back, or 10 that aren't actually the closest ones in that tenant's data. No error, no alarm, just a model answering with less context than it should have had. On September 30, 2026, AWS shipped metadata pre-filtering for S3 Vectors. Indexes now come in two modes, and the new one evaluates your filter before the similarity search instead of during it. AWS says that returns up to 5x more matching vectors when the filter is selective. It also adds a $startsWith prefix operator, sets a 100-condition limit per query, and costs nothing extra. Here's what changed, why the old behavior dropped results, how to measure the difference on your own index, and what a multi-tenant retrieval service on Amazon EKS looks like with it. CLASSIC validates the filter while searching; ENHANCED narrows the set first. (Diagram labels in Spanish, from the original article.) S3 Vectors indexes now have a mode: CLASSIC (filter evaluated in tandem with the approximate search) or ENHANCED (filter resolved first, then similarity search over the matching subset). With selective filters, ENHANCED returns up to 5x more matching vectors, per AWS. Vector buckets created on or after Sep 30, 2026 are ENHANCED-only. Older buckets stay CLASSIC until you run UpdateIndexMode; no re-ingestion needed. You can test per query with queryMode=ENHANCED before switching the index. New $startsWith operator; ENHANCED indexes cap filters at 100 conditions (each $in value counts). No additional cost. Available in every commercial Region with S3 Vectors, including São Paulo, plus the China Regions. Vector search at scale is approximate: the engine explores a neighborhood of promising candidates on a bounded budget rather than comparing your query against every vector. In CLASSIC mode, filters are checked while that exploration runs. If your filte

IAInfraDev
Interesse