Skip to content

Releases: enviodev/hyperindex

v2.27.0

07 Aug 15:14
2245985
Compare
Choose a tag to compare

What's Changed

Introducing Preload Optimization

Important! Preload optimization makes your handlers run twice.
Starting from [email protected] all new indexers are created with preload optimization pre-configured by default.

This optimization enables HyperIndex to efficiently preload entities used by handlers through batched database queries, while ensuring events are processed synchronously in their original order. When combined with the Effect API for external calls, this feature delivers performance improvements of multiple orders of magnitude compared to other indexing solutions.

Set a single line in your config and make your handlers multiple times faster without changing a single line of code:

preload_handlers: true

For power users - This is like Loaders, but for all handlers by default.

Read more about Preload Optimization in the dedicated guide.

By @DZakh in #667

Contract-specific start block

A highly requested feature contributed by one of our users @rori4 🎉

Specify a later start block for a contract to optimize indexing performance:

name: nft-indexer
description: NFT Factory
networks:
  - id: 1337
    start_block: 0
    contracts:
      - name: NftFactory
        address: 0x4675a6B115329294e0518A2B7cC12B70987895C4
        handler: src/EventHandlers.ts
        events:
          - event: SimpleNftCreated(string name, string symbol, uint256 maxSupply, address contractAddress)

      - name: Nft
        # No address field - we'll discover these addresses from SimpleNftCreated events
        start_block: 
        handler: src/EventHandlers.ts
        start_block: 30000000 # Overwrite the network start block
        events:
          - event: Transfer(address from, address to, uint256 tokenId)

In the Factory Contract example above, it'll register all NFT addresses, but it'll start processing Transfers only from the block 30000000.

Implemented in #669, #670.

Contributing Improvements

To support new contributors, we have updated our CONTRIBUTING.md file with a detailed guide on navigating the HyperIndex codebase, as well as examples of what a change would look like. To make it even easier, we added .cursor rules to help develop new HyperIndex features.

By @DZakh in #661

Embrace Vibe-Coding

All new projects are now created with an initial .cursor rules included to help you build indexers with the agent support.

Also, feel free to create PRs with the rules suggestions to improve the experience for everyone 😉

By @DenhamPreen in #663, #671

Fixes & Improvements

  • Started including an address in a handler error log by @DZakh in #658
  • Support nullable effect cache output by @DZakh in #665
  • Fix e2e tests by @DZakh in #666
  • Error when contract start block is earlier than the network's by @DZakh in #670

New Contributors

Full Changelog: v2.26.0...v2.27.0

v2.26.0

29 Jul 14:38
36cd685
Compare
Choose a tag to compare

🆕 Built-in Cache for Effect Calls

import { experimental_createEffect, S } from "envio";

export const getMetadata = experimental_createEffect(
  {
    name: "getMetadata",
    input: S.string,
    output: {
      description: S.string,
      value: S.bigint,
    },
    cache: true, // Simply set cache to true
  },
  async ({ input, context }) => {}
})

Read more in the docs, learn how to persist the cache on reruns, and share it with Hosted Service (alpha).

🧹 Other changes

  • Now it's possible to disable Hasura integration via ENVIO_HASURA=false environment variable.
  • Started using Postgres 17 for local development
  • Added ENVIO_INDEXER_PORT env var (Instead of deprecated METRICS_PORT)
  • Added ENVIO_PG_PASSWORD env var (Instead of deprecated ENVIO_POSTGRES_PASSWORD)
  • Removed uninformative text from TUI and included the GraphQL endpoint instead.
  • Fixed indexers with non-public schema

Full Changelog: v2.25.3...v2.26.0

v2.26.0-rc.2

24 Jul 10:18
Compare
Choose a tag to compare
v2.26.0-rc.2 Pre-release
Pre-release

v2.26.0-rc.1

23 Jul 08:55
3d93d2d
Compare
Choose a tag to compare
v2.26.0-rc.1 Pre-release
Pre-release

What's Changed

  • Fix sei-apis rpc error handling by @DZakh in #654

Full Changelog: v2.26.0-alpha.8...v2.26.0-rc.1

v2.26.0-alpha.9

22 Jul 07:19
5533b68
Compare
Choose a tag to compare
v2.26.0-alpha.9 Pre-release
Pre-release

What's Changed

  • Fix sei-apis rpc error handling by @DZakh in #654

Full Changelog: v2.25.2...v2.26.0-alpha.9

v2.26.0-alpha.8

21 Jul 07:42
Compare
Choose a tag to compare
v2.26.0-alpha.8 Pre-release
Pre-release

v2.26.0-alpha.7

18 Jul 14:49
Compare
Choose a tag to compare
v2.26.0-alpha.7 Pre-release
Pre-release

v2.26.0-alpha.6

18 Jul 14:28
Compare
Choose a tag to compare
v2.26.0-alpha.6 Pre-release
Pre-release

v2.26.0-alpha.5

17 Jul 14:27
Compare
Choose a tag to compare
v2.26.0-alpha.5 Pre-release
Pre-release

v2.26.0-alpha.4

17 Jul 10:33
Compare
Choose a tag to compare
v2.26.0-alpha.4 Pre-release
Pre-release