Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

    Parameters —

             name &actor
               string &fio_domain
               uint64_t &sale_price
               uint64_t &max_fee
               string &tpid

...

            Owner of domain updated in domains table (fio.address) no RAM impact.            

            Entry added into domain sales containing

                 d.id      
                 d.owner       
                 d.ownerhash      
                 d.domain         
                 d.domainhash     
                 d.sale_price    
                 d.commission_fee
                 d.date_listed
                 d.date_updated   
                 d.status       

Recommendation — Since a record containing the above data is added to a table. Consider to increase RAM bump on this command from the present 512 which seems in-adequate, Add print statements and get the TX size, (1.5 X this for the RAM bump)…Cxlistdomain

RAM Analysis by Thomas

I used cryptonym to execute a transaction and looked at the "account_ram_delta" key

Code Block
languagejson
"account_ram_deltas": [
  {
    "account": "wjeo4abnk4c2",
    "delta": 755
  }
],

Based on this output the account wjeo4abnk4c2 requires 755 bytes of RAM. Using the standard formula of usage x 1.5 I am increasing the ram by 1140 bytes rounding up a little from 755x1.5.

cxlistdomain --

       Parameters —

              name &actor,
               string &fio_domain,
               int64_t &max_fee,
               string &tpid

...

       Recommendation — reduce RAM bump to be 256 on this call.

RAM Analysis by Thomas

Looking at the "account_ram_deltas" from the tx response of cxlistdomain:

Code Block
languagejson
"account_ram_deltas": [
  {
    "account": "fio.escrow",
    "delta": 463
  },
  {
    "account": "wjeo4abnk4c2",
    "delta": -463
  }
],

This removes the RAM from the user account and increases on fio.escrow so it seems like no RAM bump is required at all.

   Buy domain

        Parameters —

               name &actor, const int64_t &sale_id,
               string &fio_domain, const int64_t &max_buy_price,
                 int64_t &max_fee, const string &tpid

         Tables updated

           

...

Domain sales status updated to “sold”.

           Recommendation — reduce RAM bump to be 256 on this call.

...

              Tables updated
                   mrkplconfigs row added

                             row.id           
                               row.owner          = actor.value;
                               row.ownerhash      = ownerHash;
                               row.commission_fee = commission_fee;
                               row.listing_fee    = listing_fee;
                               row.e_break        = e_break;

                   Recommendation — increase RAM bump on this command from the present 512 which seems in-adequate,   Add print statements and get the TX size, (1.5 X this for the RAM bump)…  Cxburned

RAM Analysis by Thomas

When looking at the response object of a setmrkplcfg action, there are no ram_deltas even though I am changing settings.

cxburned

           Only called by a FIO system contract (with unlimited resources) no ram bump needed….

...