create account

[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL by mahdiyari

View this thread on: hive.blogpeakd.comecency.com
· @mahdiyari · (edited)
$33.06
[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL
<center>![hafsql.png](https://images.hive.blog/1536x0/https://files.peakd.com/file/peakd-hive/mahdiyari/23uEsNRBN8VFqNkR4aCSQNwDRgLN2G4wfa9XnM9DyWZQwdrNaay2JikkpGnTU2eaS7JzA.png)</center>
I have been providing public access to a HAF + HafSQL database for the past 3 months. Alongside with a backup server to keep the downtimes minimal.

I do provide a few free services including public API nodes which require some beefy machines. I do that because of my witness rewards and it is all voluntary.

This public database is adding up a bit. It also doesn't help that I launched a new public RPC node in USA which is expensive compared to EU. I was considering removing the backup server which will add at least 48 hours of downtime on every upgrade or a possible crash/issue. I'll probably remove the USA RPC node as well as I don't think it is really needed right now considering the number of public nodes we have. But I thought it is worth giving DHF a shot as the provided service is beneficial to the apps and developers.

### Funding
- Server cost - 1 main server - 1 backup server
- Partial development/maintenance cost

This is not only for the server cost and includes development as well.

HafSQL was originally paid by DHF but I have been working on it since then. I added some new features and updated the code to work with the newer versions of the HAF (since the original code was for v1.27.4.0). Currently I know Inleo team is using their own local HafSQL for some part of their website and I know peakd is developing their polling system with HafSQL.

### What I promise
- To keep the public database running (`hafsql.mahdiyari.info`) + backup server[s]
- Keep HafSQL working with newer versions of HAF
- Add new/requested features by the apps or developers
- If the project is ended by any event such as lack of work, I will return the unused funds minus the server costs for the year to the DHF treasury.

I'll do my best to keep the database open to the public as I have been doing for a while even if there was no funding.
***
### Development
I did develop an experimental version of reputations and due to lack of feedback is still considered under development. The other features I'm interested in are the data included in Hivemind as I have been asked by other devs. I was thinking about implementing features present in Hivemind in a modular way. Reputations was the first but since there were talks about removing the reputations entirely, I did implement a modified version as an alternative for testing which is way faster to sync. The added features will be optional just like the already present features. You can choose what you want in your database when running the HafSQL app.
Currently syncing HafSQL takes less than 24 hours. And syncing hivemind takes at least a week. For a full node you need hivemind as all social side is handled by hivemind.

My goal would be to remove Hivemind and have a modular HafSQL which can replace Hivemind seamlessly. Which would include development of the APIs supported by hivemind. Also I don't intend to drag the development an entire year and will try to wrap it up faster if possible. And of course this goal can change depending on the request of the apps and developers.
***
The details for the public database are in this post: [Public HafSQL database on HAF](/hive-139531/@mahdiyari/public-hafsql-database-on-haf)

GitLab links: 
https://gitlab.com/mahdiyari/hafsql
https://gitlab.com/mahdiyari/hafsql-api

I appreciate your support. Feedback is most welcome. Feel free to comment your questions or concerns about the proposal or the project.

Proposal links:
Proposal number 301
[Peakd](https://peakd.com/me/proposals/301)
[Ecency](https://ecency.com/proposals/301)
👍  , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , and 382 others
properties (23)
authormahdiyari
permlinkproposal-public-haf-hafsql-database-maintenance-and-development-of-hafsql
categoryhive-139531
json_metadata{"tags":["hive","dev","hivedev","haf","hafsql","dhf","proposal"],"image":["https://images.hive.blog/1536x0/https://files.peakd.com/file/peakd-hive/mahdiyari/23uEsNRBN8VFqNkR4aCSQNwDRgLN2G4wfa9XnM9DyWZQwdrNaay2JikkpGnTU2eaS7JzA.png"],"links":["/hive-139531/@mahdiyari/public-hafsql-database-on-haf"],"app":"hiveblog/0.1","format":"markdown","users":["mahdiyari"]}
created2024-03-26 21:33:54
last_update2024-03-26 21:54:45
depth0
children14
last_payout2024-04-02 21:33:54
cashout_time1969-12-31 23:59:59
total_payout_value16.574 HBD
curator_payout_value16.482 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length3,740
author_reputation199,858,009,060,549
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,360,099
net_rshares61,100,058,042,230
author_curate_reward""
vote details (446)
@axobtc ·
$0.04
properties (23)
authoraxobtc
permlinkre-mahdiyari-sg6brq
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.7.2"}
created2024-07-05 23:26:15
last_update2024-07-05 23:26:15
depth1
children0
last_payout2024-07-12 23:26:15
cashout_time1969-12-31 23:59:59
total_payout_value0.022 HBD
curator_payout_value0.022 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length10
author_reputation3,120,321,230,378
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id135,095,123
net_rshares150,421,834,173
author_curate_reward""
vote details (5)
@chefbgob ·
Was scared about the notice, but seems cool. Thank you
properties (22)
authorchefbgob
permlinkre-mahdiyari-sbhsvt
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.4.1"}
created2024-04-05 23:21:30
last_update2024-04-05 23:21:30
depth1
children0
last_payout2024-04-12 23:21:30
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length54
author_reputation7,012,460,252,519
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,632,529
net_rshares0
@ctrpch ·
$1.20
I support this proposal, you are not asking for much compared to the value that you are giving. 

Keep up the good work mate.
👍  , , , ,
properties (23)
authorctrpch
permlinkre-mahdiyari-saztw3
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.3.6"}
created2024-03-27 06:26:30
last_update2024-03-27 06:26:30
depth1
children0
last_payout2024-04-03 06:26:30
cashout_time1969-12-31 23:59:59
total_payout_value0.600 HBD
curator_payout_value0.599 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length125
author_reputation95,137,497,861,948
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,368,402
net_rshares2,343,279,379,648
author_curate_reward""
vote details (5)
@frgnholding ·
$0.02
Public HAF/HafSQL database maintenance & development of HafSQL #301 supported
👍  , ,
properties (23)
authorfrgnholding
permlinkre-mahdiyari-sfe907
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.6.6"}
created2024-06-20 19:33:45
last_update2024-06-20 19:33:45
depth1
children0
last_payout2024-06-27 19:33:45
cashout_time1969-12-31 23:59:59
total_payout_value0.012 HBD
curator_payout_value0.012 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length77
author_reputation324,715,797,596
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id134,746,674
net_rshares81,625,150,305
author_curate_reward""
vote details (3)
@museodelcaos ·
$0.02
Proposal supported 
👍  , , ,
properties (23)
authormuseodelcaos
permlinkre-mahdiyari-sfs50f
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.6.10"}
created2024-06-28 07:33:51
last_update2024-06-28 07:33:51
depth1
children0
last_payout2024-07-05 07:33:51
cashout_time1969-12-31 23:59:59
total_payout_value0.010 HBD
curator_payout_value0.010 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length19
author_reputation1,157,920,602,047
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id134,935,104
net_rshares76,731,147,721
author_curate_reward""
vote details (4)
@nonameslefttouse ·
$0.30
Peakd just sent me a pop up alerting me of this proposal.  *So smart.*
👍  
properties (23)
authornonameslefttouse
permlinkre-mahdiyari-sazes9
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.3.6"}
created2024-03-27 01:00:09
last_update2024-03-27 01:00:09
depth1
children0
last_payout2024-04-03 01:00:09
cashout_time1969-12-31 23:59:59
total_payout_value0.148 HBD
curator_payout_value0.148 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length70
author_reputation593,361,688,458,528
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,363,904
net_rshares554,833,985,045
author_curate_reward""
vote details (1)
@rishi556 ·
Any chance we can get an AAAA (IPv6 record) on hafsql.mahdiyari.info?
properties (22)
authorrishi556
permlinkre-mahdiyari-sftzv8
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.6.10"}
created2024-06-29 07:37:57
last_update2024-06-29 07:37:57
depth1
children2
last_payout2024-07-06 07:37:57
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length69
author_reputation131,998,138,469,997
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id134,958,416
net_rshares0
@mahdiyari ·
Can you check and see if it works now?
properties (22)
authormahdiyari
permlinkre-rishi556-sfuist
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.6.10"}
created2024-06-29 14:27:00
last_update2024-06-29 14:27:00
depth2
children1
last_payout2024-07-06 14:27:00
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length38
author_reputation199,858,009,060,549
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id134,963,739
net_rshares0
@rishi556 · (edited)
Well, Wednesday has passed and I forgot to let you know but it's working great! Thanks again!

~~I can telnet to the Postgres port so I'd guess it's working. Will verify Wednesday. Thanks!~~
properties (22)
authorrishi556
permlinkre-mahdiyari-sfzciv
categoryhive-139531
json_metadata{"app":"peakd/2024.6.10","tags":["hive-139531"]}
created2024-07-02 04:59:18
last_update2024-07-25 23:44:48
depth3
children0
last_payout2024-07-09 04:59:18
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length190
author_reputation131,998,138,469,997
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id135,013,527
net_rshares0
@rishi556 ·
How much additional space does the HAFSQL take to run alongside a Hive full node running hivemind and HAF?
properties (22)
authorrishi556
permlinkre-mahdiyari-sh7e5c
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.7.3"}
created2024-07-25 23:48:48
last_update2024-07-25 23:48:48
depth1
children2
last_payout2024-08-01 23:48:48
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length106
author_reputation131,998,138,469,997
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id135,593,137
net_rshares0
@mahdiyari ·
$0.05
It should be around 500gb with lz4 compression.
👍  
properties (23)
authormahdiyari
permlinkre-rishi556-sh85ql
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.7.3"}
created2024-07-26 09:44:54
last_update2024-07-26 09:44:54
depth2
children0
last_payout2024-08-02 09:44:54
cashout_time1969-12-31 23:59:59
total_payout_value0.024 HBD
curator_payout_value0.024 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length47
author_reputation199,858,009,060,549
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id135,605,354
net_rshares155,465,760,876
author_curate_reward""
vote details (1)
@mahdiyari ·
I did actually test this now and it is 275618944 bytes or 262 GB (with lz4).
properties (22)
authormahdiyari
permlinkre-rishi556-shggau
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.7.4"}
created2024-07-30 21:13:51
last_update2024-07-30 21:13:51
depth2
children0
last_payout2024-08-06 21:13:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length76
author_reputation199,858,009,060,549
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id135,796,810
net_rshares0
@tranquil3 ·
$0.24
Your transparency is commendable and I think keeping the database open to the public would be a nice one. 
👍  
properties (23)
authortranquil3
permlinkre-mahdiyari-2024327t35425221z
categoryhive-139531
json_metadata{"type":"comment","tags":["hive-139531","hive","dev","hivedev","haf","hafsql","dhf","proposal"],"app":"ecency/3.0.46-mobile","format":"markdown+html"}
created2024-03-27 02:54:30
last_update2024-03-27 02:54:30
depth1
children0
last_payout2024-04-03 02:54:30
cashout_time1969-12-31 23:59:59
total_payout_value0.122 HBD
curator_payout_value0.122 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length106
author_reputation47,797,225,083,136
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,365,533
net_rshares460,140,957,313
author_curate_reward""
vote details (1)
@wrestlingdesires ·
I supported it :) Thanks so much for your work 🙌


This post has been manually curated by the VYB curation project
properties (22)
authorwrestlingdesires
permlinkre-mahdiyari-sbbn3c
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2024.4.1"}
created2024-04-02 15:30:51
last_update2024-04-02 15:30:51
depth1
children0
last_payout2024-04-09 15:30:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length114
author_reputation202,687,906,055,991
root_title"[Proposal] Public HAF/HafSQL database maintenance & development of HafSQL"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id132,542,377
net_rshares0