Pages:
Author

Topic: BIP 106: Dynamically Controlled Bitcoin Block Size Max Cap (Read 9415 times)

legendary
Activity: 3794
Merit: 1375
Armory Developer
As I can see, you have talked about various numbers, like 66~75%, 20% etc. These appears to be magic number to me, like BIP 101's 8mb or BIP 103's 4.4% & 17.7%. How do you derive them ?

I've said stated all these figures need to be discussed. I believe these thresholds need to exist, but a decent value or a decent way to compute these values needs to be discussed. I can give you the reason these values need to exists but I have not done the research to determine which figures are the most appropriate, of it there is a way to set these dynamically as well.

The 66~75% figure is a proposal for the block space usage threshold at which a resizing should be tested against secondary conditions. The rationale is that organic market growth will always burst through any threshold (until it hits a hard cap eventually), whereas an attacker won't necessarily. Raising the space usage threshold increases the effort required by ill intentioned parties, and doesn't change a thing for natural market growth. As a reminder, the current threshold is 50%.

The 20% figure denotes the fee growth threshold, i.e. a resizing should only occur if fees have gone X% either way compared to the previous period. Currently there is no such threshold, making it trivial for any attacker to push up the block size and maintain it high.

As long as these thresholds are in place and tight enough, an effective decay function can be implemented. The goal is to distinguish between organic growth in demand and spam attacks, and use a safety net mechanism (the decay function) to correct all growth that is not supported by actual demand. It would actually mimic commodity prices in a speculative market: large speculators can pump the price for a while but eventually the market will always correct itself, with the valid demand as its baseline.

The first threshold is not very important. It will always be reached first when demand climbs, so its particular value is not all that important. It could be 90% for all I care, because fees won't start climbing until blocks are nearing max capacity. It needs to be > 50% to make room for the decay function.

The threshold that needs to be truly discussed is the second one. It can't be low enough that an attacker can throw a couple extra BTC at the network and trigger a size growth on the cheap under the right conditions. It can't be so big the network will get clogged with a massive backlog before it resizes. However, an increase in fee subsidy is an increase in revenue, which will translate into an increase mining power eventually. It can be expected that such tight thresholds will result in bursty cap growths, which is another reason for a decay function, but generally I believe we are better with high values than low ones.
full member
Activity: 214
Merit: 278
Thanks to everyone for providing good arguements for improvement of the proposal. I have derived a second proposal and updated OP accordingly. If you have any counter-arguement to this proposal, feel free to put it here or in the comment section of the article - http://upalc.com/maxblocksize.php

I would insist on implementing a decay function for the sake of spam control and to prevent gaming the system.

I will repeat my point: the status quo path, where the current size is maintained if no increase/decrease is triggered is damaging in that it becomes trivial to maintain a size increase after a spam attack or in case a miner wants to game the system. At the same time a decrease becomes quasi impossible with the current thresholds.

An increase should be triggered at 66~75% capacity, not ~50%, and the fees should be at least 20% superior to the cumulated subsidy of the previous period. This is critical as it forces an attacker to compound his effort to inflict several unnatural increase on the network instead of simply giving the network a nudge and maintaining the increase trivially.

The goal of this proposal is to automatically adapt the max block size to the demand, not to offer a voting mechanism where spammers and large miners alike can pump up the block size and keep it there at minimal cost. If this is what you are aiming for, then Garzik's approach makes more sense.

In order to dynamically resize the block ceiling, the algorithm needs to distinguish between spam/attacks and organic growth. The simplest way to one from the other is that spam is acute, organic growth is chronic (or long lasting if you prefer). This means natural growth will always eventually trigger an increase, which is why tighter thresholds make sense. Natural growth will always manage to get to a sane threshold, but the higher the threshold, the more expensive it is to game the system.

However, in case the attacker is willing to pay the price for an upscaling, the effect of that attack should fade once the attack is over, which why we should have a decay function instead of a status quo condition. Only organic growth will be powerful enough to maintain a ceiling increase. With proper thresholds, an attacker would have to keep on spending more fees and increasing the difficultly significantly to keep the ceiling on growing, which is the only way he'd have to force in a lasting effect. At this point he is better off just mining for profit as a sane market actor, which is what a PoW blockchain relies on to begin with: there is more profit in participating to the network than to attack it.

As I can see, you have talked about various numbers, like 66~75%, 20% etc. These appears to be magic number to me, like BIP 101's 8mb or BIP 103's 4.4% & 17.7%. How do you derive them ?
full member
Activity: 165
Merit: 102
This BIP has now been assigned a BIP number and pulled into BIP repository on Github.

BIP 106: https://github.com/bitcoin/bips/blob/master/bip-0106.mediawiki
newbie
Activity: 6
Merit: 0
Good job OP! I've seen this discussion about dynamic block size about 2 years ago, but no one was able to introduce it formally.

I would prefer the proposal 1 (keep it simple) with some modifications, in order to not have a unnecessary block size. Imagine an actual block size of 20mb. The next jump would be 40mb to just use maybe 22mb.

I suggest to sum a discrete amount to Maxblock size (e.g 12.5%) up to doubling it the current day (~next 144 blocks).

Code:
If more than 50% of block's size, found in the first 2000 of the last difficulty period, is more than 90% MaxBlockSize
    MaxBlockSize = MaxBlockSize+ 12.5%
    Limit = Double MaxBlockSize_last_144

I think increasing by discrete amounts can damp the system, making the block size more predicable and reducing the tx fee gambling.

The same principle can be added to cut block size.

 


legendary
Activity: 1064
Merit: 1000
Have you submitted this to gmaxwell yet for bip number assignment? If you did, what was his response?

I did. On August 18, 2015 he said that normal procedure is to allow some time for discussion on the list and asked me to post the draft text as well. I did not have the draft text ready by then. As you'll see the draft (https://github.com/UpalChakraborty/bips/blob/master/BIP-DynamicMaxBlockSize.mediawiki) was made on August 24, 2015. So, after posting the draft text, I contacted him again for BIP no. Since then, I have not heard of him.

Did you formally request the BIP number? Can I suggest you open a PR in the bips repository and gmaxwell can assign you a number there. That's how I got mine for BIP 105.

Wont BIP 105 be included under https://github.com/bitcoin/bips/ like BIP 101 ?

It's there as a pull request for the time being: https://github.com/bitcoin/bips/pull/187. I think there's still plenty room for some discussions.
full member
Activity: 214
Merit: 278
Have you submitted this to gmaxwell yet for bip number assignment? If you did, what was his response?

I did. On August 18, 2015 he said that normal procedure is to allow some time for discussion on the list and asked me to post the draft text as well. I did not have the draft text ready by then. As you'll see the draft (https://github.com/UpalChakraborty/bips/blob/master/BIP-DynamicMaxBlockSize.mediawiki) was made on August 24, 2015. So, after posting the draft text, I contacted him again for BIP no. Since then, I have not heard of him.

Did you formally request the BIP number? Can I suggest you open a PR in the bips repository and gmaxwell can assign you a number there. That's how I got mine for BIP 105.

Wont BIP 105 be included under https://github.com/bitcoin/bips/ like BIP 101 ?
legendary
Activity: 1064
Merit: 1000
Have you submitted this to gmaxwell yet for bip number assignment? If you did, what was his response?

I did. On August 18, 2015 he said that normal procedure is to allow some time for discussion on the list and asked me to post the draft text as well. I did not have the draft text ready by then. As you'll see the draft (https://github.com/UpalChakraborty/bips/blob/master/BIP-DynamicMaxBlockSize.mediawiki) was made on August 24, 2015. So, after posting the draft text, I contacted him again for BIP no. Since then, I have not heard of him.

Did you formally request the BIP number? Can I suggest you open a PR in the bips repository and gmaxwell can assign you a number there. That's how I got mine for BIP 105.
legendary
Activity: 3794
Merit: 1375
Armory Developer
Be fair on yourself. You have a more authoritative view than most others, seeing as your work (designing & implementing the block handling + storage for a major Bitcoin wallet) deals with both the subtle details and the overarching dynamics of this very topic (at least in respect of how Bitcoin works now).

I have no experience with network design so I can't alone come up with a proposal that accounts for the entire engineering scope the metric affects. Maybe I would be more motivated to run with my own proposal and implementation if I did.
legendary
Activity: 3430
Merit: 3080
If I believed I had some authority in this matter, I would just go ahead and implement my own proposal.

Be fair on yourself. You have a more authoritative view than most others, seeing as your work (designing & implementing the block handling + storage for a major Bitcoin wallet) deals with both the subtle details and the overarching dynamics of this very topic (at least in respect of how Bitcoin works now).
legendary
Activity: 3794
Merit: 1375
Armory Developer
I would insist on implementing a decay function for the sake of spam control and to prevent gaming the system.
Assuming all your suggestions are implemented by OP, will Armory publicly come out in support of this proposal ? I am having a feeling that without support from any major player BIPs are just meaningless. Moreover, if the proposal is not from a core dev, it would get a hard time in getting even a BIP no.

No, I speak for myself in all these matters. Etotheipi sets the technical stance for Armory. I've been a bitcointalk member since before Armory even existed, I believe that is sufficient a distinction to signify that my position is personal and does not reflect what Armory as a business believes is the better route.

If this proposal gets enough discussion and refinement, I may implement it myself to speed up the BIP number processing. Historically, Armory has been pretty neutral in consensus discussions, so I do not believe it makes us a big player in this particular field or that my voice as an Armory employee carries more than any other poster in D&DT.

If I believed I had some authority in this matter, I would just go ahead and implement my own proposal.
legendary
Activity: 1662
Merit: 1050
I would insist on implementing a decay function for the sake of spam control and to prevent gaming the system.
Assuming all your suggestions are implemented by OP, will Armory publicly come out in support of this proposal ? I am having a feeling that without support from any major player BIPs are just meaningless. Moreover, if the proposal is not from a core dev, it would get a hard time in getting even a BIP no.
legendary
Activity: 3794
Merit: 1375
Armory Developer
Thanks to everyone for providing good arguements for improvement of the proposal. I have derived a second proposal and updated OP accordingly. If you have any counter-arguement to this proposal, feel free to put it here or in the comment section of the article - http://upalc.com/maxblocksize.php

I would insist on implementing a decay function for the sake of spam control and to prevent gaming the system.

I will repeat my point: the status quo path, where the current size is maintained if no increase/decrease is triggered is damaging in that it becomes trivial to maintain a size increase after a spam attack or in case a miner wants to game the system. At the same time a decrease becomes quasi impossible with the current thresholds.

An increase should be triggered at 66~75% capacity, not ~50%, and the fees should be at least 20% superior to the cumulated subsidy of the previous period. This is critical as it forces an attacker to compound his effort to inflict several unnatural increase on the network instead of simply giving the network a nudge and maintaining the increase trivially.

The goal of this proposal is to automatically adapt the max block size to the demand, not to offer a voting mechanism where spammers and large miners alike can pump up the block size and keep it there at minimal cost. If this is what you are aiming for, then Garzik's approach makes more sense.

In order to dynamically resize the block ceiling, the algorithm needs to distinguish between spam/attacks and organic growth. The simplest way to one from the other is that spam is acute, organic growth is chronic (or long lasting if you prefer). This means natural growth will always eventually trigger an increase, which is why tighter thresholds make sense. Natural growth will always manage to get to a sane threshold, but the higher the threshold, the more expensive it is to game the system.

However, in case the attacker is willing to pay the price for an upscaling, the effect of that attack should fade once the attack is over, which why we should have a decay function instead of a status quo condition. Only organic growth will be powerful enough to maintain a ceiling increase. With proper thresholds, an attacker would have to keep on spending more fees and increasing the difficultly significantly to keep the ceiling on growing, which is the only way he'd have to force in a lasting effect. At this point he is better off just mining for profit as a sane market actor, which is what a PoW blockchain relies on to begin with: there is more profit in participating to the network than to attack it.
full member
Activity: 411
Merit: 101
🦜| Save Smart & Win 🦜
It has come to my understanding (please correct me if I am wrong and why) that miners can inject bogus transactions in their blocks.

If that is true then this proposal is crap: miners can put whatever transactions with whatever fees to inflate the statistic to suit whatever new block size they target.

I firmly believe miners will do whatever it takes to make the blocksize as large as they can make it, via whatever mechanism allowed (includingi BIP100) since it will give them maximum flexibiility to decide. They can always soft limit if they choose after all.
staff
Activity: 3458
Merit: 6793
Just writing some code
So one thing that people have pointed out in other threads that also mention this proposal is that a someone can spam transactions which fill blocks and forces the block limit up. Miners can also lower the block limit to an infinitely small amount. I think you should also add in upper and lower bounds on what the block size limit can be. Perhaps 1 MB and 32 MB to prevent this kind of thing from happening.
full member
Activity: 214
Merit: 278
I was not calculating transaction fees in cents, I was referring to the value of the transaction using an arbitrary exchange rate (USD) rather than the actual quantity of bitcoins in the transaction fee.

The point is that the rising value of Bitcoin could make transaction fee amounts in bitcoins appear to go down, even if the value of transaction fees is actually going up. This would deadlock this algorithm over the period of increasing value.
Users can always spend what they feel correct to include their Tx in block. On ther other hand, miners can always chose which Tx they'll add. Now, if Tx fee goes down, but FIAT value of Tx fee goes up, then market will decide whether they'll still lower Tx fee or not. Bitcoin protocol do have this freedom and this proposal does not seem to block that either. So, I dont see any deadlock situation to arise.

Looking at a different problem with the new proposal, the new checks were designed so that it would make sure transaction fees were going up before a block size increase took place, but it only considers the last ~4000 blocks (~27 days), so if transaction fees fall to any degree over a 27 day period and then rise, the check can be passed. In that way nodes would still consolidate to compete at lower transaction fees and larger blocks.
This could easily be gamed by paying huge transaction fees to oneself at the ending of this period, which costs a miner virtually nothing.
Can not be gamed so easily, because this is not the only one check in proposal 2. There are two other checks as well and when all the three checks are satisfied over a period of time, then you can safely assume that the Tx volume is really increasing and max block size increase is happening due to market demand. Even if all these three parameters are gamed, miners have to keep burning an increasing amount of money to keep max block size cap up. If it is artificially increased, it'll automatically come down in coming difficulties, as soon as miners stop burning their money.
full member
Activity: 165
Merit: 102
Have you submitted this to gmaxwell yet for bip number assignment? If you did, what was his response?

I did. On August 18, 2015 he said that normal procedure is to allow some time for discussion on the list and asked me to post the draft text as well. I did not have the draft text ready by then. As you'll see the draft (https://github.com/UpalChakraborty/bips/blob/master/BIP-DynamicMaxBlockSize.mediawiki) was made on August 24, 2015. So, after posting the draft text, I contacted him again for BIP no. Since then, I have not heard of him.
staff
Activity: 3458
Merit: 6793
Just writing some code
Have you submitted this to gmaxwell yet for bip number assignment? If you did, what was his response?
full member
Activity: 165
Merit: 102
I have a meta-question... why the details (in the first OP post) are a (dynamic) PHP page?

Do you mean http://upalc.com/maxblocksize.php ?

Yes, that is what I mean.
BTW, I tried to contribute to your redit thread, but the formating and linebreaks there are mess, I hed to redelet my post 4 times :-). So I hope I did not cause any problems.

Well, upalc.com is my personal blog and there are many common sections in the article pages. Hence I coded them in PHP.

Regarding the reddit post, it is not mine. I posted the BIP draft in bitcoin dev-list as per GMaxwell's suggestion. Someone read it there and posted it in reddit. But, I dont think, posting and editing your own post will create any problem for anyone.
sr. member
Activity: 475
Merit: 255
I have a meta-question... why the details (in the first OP post) are a (dynamic) PHP page?

Do you mean http://upalc.com/maxblocksize.php ?

Yes, that is what I mean.
BTW, I tried to contribute to your redit thread, but the formating and linebreaks there are mess, I hed to redelet my post 4 times :-). So I hope I did not cause any problems.
sr. member
Activity: 433
Merit: 267
Oh, I didn't realize a second different algorithm was made.
One problem with the new one is that it presumes that Bitcoin transaction fees, in bitcoins, should always go up with a block size increase, which isn't always the case.
I dont see it is assumed anywhere. Tx fee has just been added as an extra filter criteria. Max block cap will rise, only if both block size & Tx fee increases.

If 1 TPS costs 1 cent to fund a healthy network, and a bitcoin costs 1 cent, then 1 TPS would cost 1 bitcoin to move.
If the network grows to 2 TPS, and bitcoin's value triples to 3 cents, then 2 TPS would cost .66 bitcoin to move.
So you could have the case where transaction fees could be bid up to .9 bitcoin, well into healthy territory, but it would appear that transaction fees, in bitcoin, have actually gone down substantially.
This is a wrong way to create fictitious situation. Tx fee shold not be calculated in cent. Do it in bitcoin and you'll have your answer. No one will pay 1 BTC to move 1 BTC. Do you see anyone paying 10000 satoshi to move 10000 satoshi ? But, if you want to move 10000 satoshi you still have to pay 10000 satoshi or 0.0001 BTC. If you remove economics and only discuss technology, then bitcoin is a fallacy.

I was not calculating transaction fees in cents, I was referring to the value of the transaction using an arbitrary exchange rate (USD) rather than the actual quantity of bitcoins in the transaction fee.

The point is that the rising value of Bitcoin could make transaction fee amounts in bitcoins appear to go down, even if the value of transaction fees is actually going up. This would deadlock this algorithm over the period of increasing value.

Looking at a different problem with the new proposal, the new checks were designed so that it would make sure transaction fees were going up before a block size increase took place, but it only considers the last ~4000 blocks (~27 days), so if transaction fees fall to any degree over a 27 day period and then rise, the check can be passed. In that way nodes would still consolidate to compete at lower transaction fees and larger blocks.
This could easily be gamed by paying huge transaction fees to oneself at the ending of this period, which costs a miner virtually nothing.
Pages:
Jump to: