Commit Graph

638 Commits

Author SHA1 Message Date
Sanjay
f7a62a52f1 chore: Release 1.2.2 (#949) @farcaster/hubble@1.2.2 @farcaster/hub-nodejs@0.7.2 @farcaster/core@0.7.2 @farcaster/hub-web@0.3.2 2023-05-08 17:28:13 -07:00
Sanjay
1236b4e956 feat: Add a status hubble command for friendly reporting of current hub status (#944)
* feat: Suport sync status rpc call

* Add sync status hubble command

* Fix generated file

* Changeset

* Fix isSyncing check

* Rename to status and report db stats as well

* Fix error
2023-05-08 14:48:24 -07:00
Stephan Cilliers
ceac2c1bea fix: Remove stackblitz example (#930) 2023-05-08 12:50:27 -07:00
Shane da Silva
32e660a181 fix: Reduce memory consumption of replication example (#943)
We had a report of one user on modern MacBook with 16GB of memory who
was running into heap allocation issues. This was likely due to the
excessive number of promises we were creating (as well as buffering all
data for each call).

Change the logic to fetch in batches of 1K records at most. This slows
down the initial sync but should reduce the likelihood that someone will
hit a memory limit.

We also specify a custom limit in the `yarn start` command so that when
we test locally we are using the same limit as everyone else.
2023-05-05 15:53:56 -07:00
Sagar Dhawan
530878831d fix: improve handling of duplicate messages on gossip (#919)
* fix: improve handling of duplicate messages on gossip

* fix tests

* fix changeset

* make gossip backwards compatible

* fix tests
2023-05-05 13:02:52 -07:00
Sanjay
f0e4df7d78 chore: ensure we clear the event handler cache in tests (#942) 2023-05-05 12:11:09 -07:00
Shane da Silva
987e1c460b chore: Remove some unused code from replication example (#941) 2023-05-05 11:14:34 -07:00
Shane da Silva
22f53d6c2b Fix handling of conflicts on UserData insertion (#940)
We were using hash as the conflict ID instead of FID + type. Fix this.
2023-05-05 10:26:48 -07:00
Shane da Silva
cc2f5a4fae Add syncing/replication example for Postgres (#938)
Provide a working end-to-end example of syncing data from hubs to a
Postgres database.

This should work with no additional dependencies besides what you
install with `yarn install` and Docker.
2023-05-05 09:56:48 -07:00
Sanjay
5d1fef9db7 fix: Only consider a peer bad if we failed to merge a large number of messages (#939) 2023-05-04 21:36:12 -07:00
Paul Fletcher-Hill
2e633db09b feat: reject prunable messages on merge (#928)
* feat: don't merge messages that would immediately be pruned

* Fix tests and minor cleanup/review comments

* Support all other stores

* Add changeset

* use prune iterator with keys available and expand cast store tests

* re-add prune iterator args

* Additional tests

* Add tests for other stores

---------

Co-authored-by: Sanjay Raveendran <sanjayprabhu@gmail.com>
2023-05-04 10:35:32 -07:00
Paul Fletcher-Hill
d2cb5e4e30 fix: validate parentUrl and targetUrl comprehensively (#935) 2023-05-03 21:04:05 -04:00
Tiago Alves
d3f707be82 Minor fix on hubs interaction link (#931) 2023-05-02 09:31:54 -07:00
Tiago Alves
36fe1b7990 Add eventcaster hub to allowlist (#929) 2023-05-01 15:15:31 -07:00
Sanjay
6c8c05d957 fix: Fix inSync reporting true when peer is blocked from sync (#934) 2023-05-01 14:58:20 -07:00
Meyanis95
aa8f451861 Ask to run a mainnet Hub (#927) 2023-04-28 09:23:12 -04:00
Rohit Jha
806e5a1f31 chore: added jam.so peer id to mainnet allowed peers (#926) 2023-04-28 08:28:22 -04:00
Sanjay
52fc714970 chore: Release 1.2.1 (#925) @farcaster/hubble@1.2.1 @farcaster/hub-web@0.3.1 @farcaster/hub-nodejs@0.7.1 @farcaster/core@0.7.1 2023-04-27 14:36:13 -07:00
Michael Huang
6a8486017e feat: implement ViemLocalEip712Signer (#787)
* Implement viemEip712Signer

* Add tests

* clean

* Stubs

* Deps

* Fixes

* Clean

* Fix bugs

* Rename

* Add changeset

* rename

* clean up

* rename

* update import

* Upgrade

* Update test

* ViemEip712Signer -> ViemLocalEip712Signer

* clean up

* Convert hash bytes to hex string before signing

* use random wallet

* Add test for mnemonic account

* Simplify

* Use random mnemonic phrase

* More clean up

* Add comment

* refactor EIP-712 signer tests into util

* update changeset to patch core

---------

Co-authored-by: Tony D'Addeo <tony@merklemanufactory.com>
Co-authored-by: Paul Fletcher-Hill <pfletcherhill@gmail.com>
2023-04-27 12:40:35 -04:00
Vincent Liao
3af9f6e166 docs: fix 404 links in PR template (#923) 2023-04-27 08:00:52 -07:00
Sanjay
427ced4f1b feat: Remember bad peers during sync and ignore them for a while. (#920)
This helps reduce excessive sync attempts (attempting to sync
with a peer that's catching up for the first time, sync divergence
prefix bugs, etc)
2023-04-26 20:40:04 -07:00
Sanjay
421c385453 feat: Add sync stats to getInfo call (#916)
* refactor: Rename sync events flag for clarity

* feat: Add sync statuts to HubInfo RPC call

* feat: Add sync stats to getInfo rpc call

* re-patch hub-web to use default export as before

* changeset
2023-04-25 10:40:59 -07:00
Sanjay
4fc319812e fix: Dedup eth events retries by block number to save api calls (#917) 2023-04-25 10:40:42 -07:00
Varun Srinivasan
a57e335da6 chore(hub-nodejs): update write-cast example for v0.7 (#915) 2023-04-24 21:36:46 -07:00
Paul Fletcher-Hill
71e9248ec2 add @les (#914) 2023-04-24 22:15:04 -04:00
Varun Srinivasan
e53b38b9c5 docs(hubble): add pm2 logrotate, exponential backoff to address common failures (#913) 2023-04-24 15:28:38 -07:00
Varun Srinivasan
a5fa70d652 docs(hubble): use hubble/latest instead of a specific version (#912) 2023-04-24 15:05:40 -07:00
Varun Srinivasan
812386f338 chore(hub-nodejs): update write-data example (#910) 2023-04-24 14:18:24 -07:00
Paul Fletcher-Hill
38b434ae0b log when stream starts (#909) 2023-04-24 16:00:19 -04:00
Paul Fletcher-Hill
1680726c36 parse cli chunk-size as number (#908) 2023-04-24 15:29:41 -04:00
Varun Srinivasan
b225a84410 chore(hub-nodejs): add hub urls, steps to chron-feed examples (#905) 2023-04-23 21:25:27 -07:00
Crypto Benkei
8f6754df45 chore: Add mainnet peer to allowed peers (#901) 2023-04-23 20:10:33 -07:00
Varun Srinivasan
f2f7297a13 docs(hubble): add instructions for connecting to mainnet (#903)
* chore(hubble): remove all references to flatbuffers

* docs(hubble): update getting started with mainnet instructions
2023-04-21 11:02:49 -07:00
Zach Terrell
0c3c33f2b8 docs(hub-nodejs): update example (#900)
* update hub-nodejs example

* change to getSSLHubRpcClient
2023-04-20 20:22:59 -07:00
Sanjay
5cee2c5526 fix: Fix off by one error when retrying id registry event on sync (#899)
* fix: Fix off by one error when retrying id registry event on sync

* feat: Add a command line flag to resync eth events from the beginning

* Add changeset
2023-04-20 18:18:49 -07:00
Kind Jeff
7d8f1aa524 chore: add new mainnet peer for rss3 (#890)
from https://github.com/NaturalSelectionLabs
2023-04-19 21:02:19 -07:00
Niranjan Singh
9d56e84fe0 Adding @nj's PeerID to be allowed to run mainnet hub (#897) 2023-04-19 16:02:18 -07:00
Manan
f7ff9b81b0 Adding a peer for mainnet (#881) 2023-04-19 13:06:13 -07:00
Paul Fletcher-Hill
c5a6aac6e4 changeset version (#889) @farcaster/core@0.7.0 @farcaster/hubble@1.2.0 @farcaster/hub-web@0.3.0 @farcaster/hub-nodejs@0.7.0 2023-04-19 00:43:57 -04:00
Paul Fletcher-Hill
87b2789124 feat: support arbitrary target types (#847)
* support CastId embeds, url parents and reaction targets

* docs(changeset): support CastId embeds, cast parent URLs, and reaction target URLs

* fix validations test

* add version and embeds deprecated validation

* docs(changeset): upgrade to protocol version 2023.4.19

* update protobuf generated code

* add reaction service tests

* add more examples to builder tests

* add more cast and reaction tests
2023-04-18 23:10:13 -04:00
Sanjay
aabe4f21bb chore: fail the build if current version is too close to expiry (#888) 2023-04-18 18:11:45 -07:00
Sanjay
a027a3ed63 fix: compact the db occasionally when syncing to avoid db bloat (#884)
* fix: compact the db occasionally when syncing to avoid db bloat

* Additional tests and logging

* add changeset
2023-04-18 15:25:47 -07:00
Milo Watanabe
fbb78de341 add new mainnet hub (#880) 2023-04-18 11:51:46 -07:00
David Furlong
a67c7c2d6e Update allowedPeers.mainnet.ts (#886) 2023-04-18 11:49:08 -07:00
Paul Fletcher-Hill
0cb0a522b2 chore: re-organize sync engine to use submitMessage rather than mergeMessage (#878)
* upgrade hub-web in examples and move gossip to hubble

* use submitMessage for sync

* simplify logging in sync engine

* remove sync related methods from storage engine

* cleanup imports and remove test methods

* add changeset
2023-04-18 00:49:57 -04:00
Anthony D'Addeo
8a733e5243 chore: add checklist item to sign commits (#879)
* chore: add checklist item to sign commits

* Update PULL_REQUEST_TEMPLATE.md
2023-04-16 21:16:56 -05:00
github-actions[bot]
3be3a3842e version packages (#875)
Co-authored-by: Paul Fletcher-Hill <pfletcherhill@gmail.com>
@farcaster/hub-web@0.2.5
2023-04-14 11:58:16 -04:00
Paul Fletcher-Hill
ee953ec4ad fix: examples and patch hub-web to use grpc-web default export (#867)
* fix chron-feed example

* update chron-feed example

* intermediate commit

* add chron-feed hub-web example

* add changeset

* remove commented out imports from example
2023-04-14 11:16:21 -04:00
Paul Fletcher-Hill
59ea2f9d42 add release-all script (#871) 2023-04-13 00:10:07 -04:00
Paul Fletcher-Hill
31fcb95f12 chore: add release.yml github action (#870)
* add release-hubble workflow

* rename release
2023-04-12 23:44:41 -04:00