Skip to content

Currency filter + limit causes timeout #615

@linconvidal

Description

@linconvidal

Context & versions

  • Version: rosetta-java v1.3.3
  • Network: preprod
  • Endpoint: /search/transactions

Steps to reproduce

# This query times out (>600s)
curl -X POST http://localhost:8082/search/transactions \
  -H "Content-Type: application/json" \
  -d '{
    "network_identifier": {"blockchain": "cardano", "network": "preprod"},
    "currency": {"symbol": "tTEURO", "decimals": 2},
    "limit": 1
  }'

# This query works fast (~2s)
curl -X POST http://localhost:8082/search/transactions \
  -H "Content-Type: application/json" \
  -d '{
    "network_identifier": {"blockchain": "cardano", "network": "preprod"},
    "currency": {"symbol": "tTEURO", "decimals": 2}
  }'

Actual behavior

When combining currency parameter with explicit limit parameter, the query performs full blockchain scan and times out after 600+ seconds.

Expected behavior

Query with currency filter and limit=1 should return quickly (within 2-3 seconds), returning first matching transaction.

Workaround: Omit limit parameter when using currency filter - uses default limit (100) and completes in ~2s.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions