• Pricing
  • Enterprise
  • Customers
  • Blog

Chainy: Chainstack’s pivoting proxy solution

Chainstack has built a strong reputation in RPC infrastructure, offering support for 25+ protocols, and a globally-distributed geo-load-balanced node network that is highly customizable. However, our commitment to providing flexible and sophisticated solutions continues to grow, adapting to the unique demands of each client.

Here are some examples of tailored customer solutions:

  • Custom request filtering based on headers, IPs, and smart contract addresses
  • Budget control with spending limits for predictable costs
  • High-speed transaction propagation with Warp Transactions
  • Efficient JWT authorization with flexible rules

In the heart of our technology at Chainstack, you’ll find Chainy. Developed internally as a custom solution, Chainy is a flexible network proxy.

Goal: Smart contract address filtering

A customer needed request filtering for specific smart contract addresses, typically using JSON-RPC over HTTP or WebSocket. This required work at the ingress controller level (Nginx), which lacks the flexibility for such tasks:

  1. HTTP requests: Filtering might seem simple—parse the body, find a smart contract address, and return an error if needed. However, handling batched JSON-RPC requests in a single HTTP payload requires parsing and filtering each request individually, which is complex and time-consuming.
  2. WebSocket traffic: WebSocket messages are seen as raw TCP traffic by Nginx, needing initial parsing to access JSON-RPC payloads. Filtering requests and sending error responses back through WebSocket adds further complexity.

The ideal solution is to use Nginx as a simple entry point and delegate advanced functionality to a more specialized system.

Going modular with Chainy plugins

Each business requirement is broken into individual “plugins,” which are arranged sequentially in Chainy—hence the name. This design makes Chainy highly adaptable, as plugins can address specific needs while maintaining modularity.

How Chainy simplifies our development work

Chainy serves as a proxy between the ingress controller and the blockchain node. It enables custom plugins for various business requirements, with unique configurations for each blockchain node. Chainy abstracts complexities like HTTP, WebSocket, and JSON-RPC batching, allowing developers to focus purely on business logic without worrying about transport-layer intricacies.

Observable usage results

Chainy’s ability to analyze incoming traffic allows it to extract key metrics. These metrics power Grafana dashboards, providing insights like RPS, response time, response size, and RPC errors, segmented by method and node ID. Real-time monitoring is available for both HTTP and WebSocket. More details will be covered in a separate article.

How Chainy supports Chainstack node operations

Chainy has been deployed ahead of every Chainstack node, handling over 30,000 RPS. Its integration has enabled Chainstack to quickly implement new features, including:

  1. Request forwarding: A flexible all-in-one endpoint, currently forwarding heavy eth_getLogs requests to our internal Logs API.
  2. Warp Transactions: Routes requests through bloXroute for the fastest transaction propagation across the network.
  3. Rapid node Initialization: Enables instant creation of Chainstack Global Nodes, compared to minutes for regional nodes.
  4. Origin-based filtering: Protects client endpoints from unsolicited traffic.
  5. Fixed usage ceilings: Allows customers to set spending limits based on their plans, ensuring predictable costs.

Conclusion

Chainy has transformed Chainstack’s ability to deliver innovative and reliable features, solidifying our leadership in the industry. Its flexibility and extensibility have streamlined development, resulting in efficient, high-quality outcomes.

As the backbone of our tech solutions, Chainy fosters continuous innovation and supports a productive work environment for our engineers. At Chainstack, we deeply value the skills and contributions of every team member, working together to maintain cutting-edge solutions and a culture of excellence.Power-boost your project on Chainstack

Power-boost your project on Chainstack

Have you already explored what you can achieve with Chainstack? Get started for free today.

SHARE THIS ARTICLE

Test

Customer Stories

tendex

Multi-contract stress-testing to ensure smooth trading infrastructure mainnet operations.

Trust

Trust Wallet leverages a custom gateway to handle high-volumes of requests across multiple networks with a 400% ROI on nodes.

Darkpool Liquidity

Develop on various networks and protocols with ease, expanding at scale in a short period of time.