Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A timeout occurred #587

Open
heyonggl opened this issue Jan 30, 2025 · 3 comments
Open

A timeout occurred #587

heyonggl opened this issue Jan 30, 2025 · 3 comments
Labels
question Further information is requested

Comments

@heyonggl
Copy link

heyonggl commented Jan 30, 2025

Ask a question

When i upgrade to v2.4.3 ,the processing of /account/balance is so so slow, taking around 10 minutes each time.
But It did not happen in v2.3.3.
Is there any solution for this issue?

@heyonggl heyonggl added the question Further information is requested label Jan 30, 2025
@Kammerlo
Copy link
Member

Hey @heyonggl,
yes this is a known issue in this rosetta implementation the response times can be slow, if the account you are querying has to many utxos.

We implemented a new version of rosetta, which you can find here: https://github.com/cardano-foundation/cardano-rosetta-java
In this implementation it won't be the case.

@heyonggl
Copy link
Author

heyonggl commented Jan 31, 2025

Thank for your help.

There is a question for use the cardano-rosetta-java in default setting.
When i use the rostta api,the failure is occurred.

curl -X POST -H "Content-Type: application/json" -d '{"network_identifier": {"blockchain":"cardano","network":"mainnet"},"metadata": {}}' http://127.0.0.1:8082/network/status
curl: (56) Recv failure: Connection reset by peer

#docker logs rosetta -f
Network: mainnet
Starting Cardano node...
Mithril Snapshot already exists - Skipping Download...
Listening on http://127.0.0.1:12798
Stating Cardano node verification...
Started opening Volatile DB...
Started opening Ledger DB...
Started initial chain selection...
Node verification: DONElot 146712645 [###################################-----] 89.34%
Starting Cardano node synchronization...
Node synchronization: DONE 146717462/146717961 [########################################] 100.00%
Starting Cardano submit api...
Starting Postgres...

  • Starting PostgreSQL 14 database server
  • Removed stale pid file.
    Error: /usr/lib/postgresql/14/bin/pg_ctl /usr/lib/postgresql/14/bin/pg_ctl start -D /node/postgres -l /var/log/postgresql/postgresql-14-main.log -s -o -c config_file="/etc/postgresql/14/main/postgresql.conf" exited with status 1:
    2025-01-31 00:44:13.602 UTC [192926] LOG: starting PostgreSQL 14.15 (Ubuntu 14.15-1.pgdg22.04+1) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, 64-bit
    2025-01-31 00:44:13.602 UTC [192926] LOG: listening on IPv4 address "0.0.0.0", port 5432
    2025-01-31 00:44:13.602 UTC [192926] LOG: listening on IPv6 address "::", port 5432
    2025-01-31 00:44:13.607 UTC [192926] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
    2025-01-31 00:44:13.616 UTC [192927] LOG: database system was interrupted; last known up at 2025-01-31 00:35:33 UTC
    2025-01-31 00:44:13.629 UTC [192927] LOG: database system was not properly shut down; automatic recovery in progress
    2025-01-31 00:44:13.632 UTC [192927] LOG: redo starts at 7E/13858DA8
    2025-01-31 00:44:17.969 UTC [192927] LOG: invalid record length at 7E/A54A00C0: wanted 24, got 0
    2025-01-31 00:44:17.969 UTC [192927] LOG: redo done at 7E/A54A0098 system usage: CPU: user: 1.99 s, system: 2.29 s, elapsed: 4.33 s
    pg_ctl: server did not start in time
    ...fail!
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    /sbin/entrypoint.sh: line 82: [: ==: unary operator expected
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    Creating database...
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    Creating user...
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: the database system is starting up
    Starting Yaci indexer...
    Starting Rosetta API...
    Waiting Rosetta API initialization...

@Kammerlo
Copy link
Member

The databases aren't compatible between the rosetta versions. It looks like that rosetta-java having issues to start the db.

Did you start with a clean directory or did you tried to use the same db?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants