Max value in max-std-element-size ?

+2 votes
I'm trying to set it to 150KB but everything above 100KB fails.

I need to create a 102KB Transaction Filter and would like how I can work around that?

Sorry for the short description, I'm from mobile.
asked Aug 21, 2019 by tloriato

2 Answers

0 votes
 
Best answer

The latest version of MultiChain removes this limit on filter code sizes. A couple of notes:

  1. If you want to continue an existing chain you will need to upgrade its protocol to remove the previous size limit: https://www.multichain.com/developers/upgrading-nodes-chains/
  2. Think about whether the acceptfiltertimeout and sendfiltertimeout runtime parameters should be increased to allow these longer filter scripts without causing a timeout the first time they are used (this is also when they are compiled). We'll be looking into improving this behavior in future but for now you should do some testing.
answered Sep 16, 2019 by MultiChain
selected Sep 16, 2019 by tloriato
0 votes

Right now the limit is 80000 bytes or 80 KB. We'll be resolving the maximum transaction filter size issue in a future protocol upgrade, not by increasing this limit, but by changing how filters are represented to use an OP_RETURN instead of an OP_DROP. This will provide a limit of up to 64 MB.

answered Aug 21, 2019 by MultiChain
Thank you for the prompt answer! I don't suppose you have an ETA on the upgrade? I'd like to avoid forking the source-code and end up creating an incompatible version if it's relatively close?
Another question, how does this relates with the constant MAX_SCRIPT_SZ of 64kb?
Where are you seeing this constant?
OK, so I assume you mean MC_ENT_MAX_SCRIPT_SIZE - this is the maximum size of the data used for custom fields of assets and streams, and also currently determines the maximum size of filter code. In the new protocol version filter code will be expressed a different way so this limit doesn't apply. We don't have a firm ETA yet.
I'm confused by the existence of the two parameters. MC_ENT_MAX_SCRIPT_SIZE determines the maximum size of the filters, but max-std-elements also does this? And both have different parameters?
For filter scripts specifically, the effective maximum size will be the lower of these two values. Same for custom fields of assets or streams.

For other uses of OP_DROP metadata only max-std-element-size applies.
...