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

[ISSUE-1089] Collect CCTP - Metrics #1165

Merged
merged 1 commit into from
Mar 11, 2024
Merged

[ISSUE-1089] Collect CCTP - Metrics #1165

merged 1 commit into from
Mar 11, 2024

Conversation

marianososto
Copy link
Collaborator

@marianososto marianososto commented Feb 28, 2024

[ISSUE-1089] Collect CCTP - Metrics - WIP

  • Issues: [Top Contributor] Build CCTP Data #1089
  • Influx_task:
      1. every hour: collect cctp and portal_token_bridge metrics from vaa_volume_v2 measurement. Sum total_value_transferred and total_messages and store it in bucket 30 days.
      1. every day: sum the last day metrics from internal_protocols_stats_1h and store it in internal_protocols_stats_1d in bucket infinite. That'll indicate what happened during that last day.
  • Add logic in /protocols/stats handler service to return stats of CCTP and PORTAL TOKEN BRIDGE:
[
	{
		"protocol": "allbridge",
		"total_messages": 34202,
		"total_value_transferred": 15459629.317363381,
		"last_day_messages": 39,
		"last_day_diff_percentage": "0.11%"
	},
	{
		"protocol": "mayan",
		"total_messages": 440237,
		"total_value_locked": 198952446.10839057,
		"total_value_secured": 196177989.987577,
		"total_value_transferred": 320644369.86081856,
		"last_day_messages": 1817,
		"last_day_diff_percentage": "0.41%"
	},
	{
		"protocol": "portal_token_bridge",
		"total_messages": 237141,
		"total_value_transferred": 176996739621047.88,
		"last_day_messages": 90999,
		"last_day_diff_percentage": "62.27%"
	},
	{
		"protocol": "cctp",
		"total_messages": 212891,
		"total_value_locked": 1907766911.6031253,
		"total_value_transferred": 3110915639152.86,
		"last_day_messages": 113051,
		"last_day_diff_percentage": "113.23%"
	}
]

@marianososto marianososto force-pushed the 1089-sosto branch 2 times, most recently from bb8b3f5 to 803a5bb Compare March 4, 2024 12:46
@marianososto marianososto self-assigned this Mar 4, 2024
@marianososto marianososto marked this pull request as ready for review March 4, 2024 15:55
@marianososto marianososto force-pushed the 1089-sosto branch 5 times, most recently from 6a0c5f8 to 6a88f46 Compare March 7, 2024 18:11
@marianososto marianososto changed the title [ISSUE-1089] Collect CCTP - Metrics - WIP [ISSUE-1089] Collect CCTP - Metrics Mar 7, 2024
@marianososto marianososto force-pushed the 1089-sosto branch 3 times, most recently from 0430960 to 46c10b7 Compare March 8, 2024 21:08
changes

 indent

more changes on the script

 new working approach on influx task

 indent script

 tested insert

 add 2 versions of the script

multiple changes

 add 1day task

 add logic to retrieve internal protocols

 remove unecessary code

 readd empty script

fix  unit-tests and measurement namings

 fix queries

 fix alignment

rename function task

fix names

improvements on influx task

 add .run config to gitignore

add .run to gitignore

fix task and rename

working api

 multiple things

Delete .run/wormscan api.run.xml

Delete analytics/scripts/test_query.flux

wip

 multiple fixes

 fix test

wip

 fix queries

fix unit-test due to query changes
@marianososto marianososto merged commit 4009482 into main Mar 11, 2024
2 checks passed
@marianososto marianososto deleted the 1089-sosto branch March 11, 2024 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants