Skip to content

Wire EPPROM never sync to client, and inefficient storage method #3697

Description

@AlexALX

Describe the bug

This is very old story from #1338 (comment)

  1. Basically during rewrites it seems completely disabled any btns in stool, they just do nothing.
Image

Look here:

concommand.Add("wire_hdd_uploaddata", function(player, command, args)

All code block are disabled, so it never sync in this way anymore.

  1. It stores data in very inefficient way. for 256KB hdd with 32 blocks it will make 8192 .txt files in data/wireflash, each file are 744 bytes to store just 128 bytes real data. I think block should be higher to reduce that, and instead of storing using string.rep(" ",24-string.len(floatstr)) it might write data as binary. Also it even can use compression to save space.

  2. after re-paste it i have data loss, there is CRITICAL issue with not writting last index from cache! created pull wire EEPROM doesn't write last index from cache! #3696 separately

  3. Writting speed are slow, only 128 bytes per sec (32 blocks x 0.25 sec think func), so full capacity of 256kb will be written by 2048 seconds ~34 minutes. There is fallback on entity remove, which flushes all content instantly to disk, but making lag if there is a lot of data left.

How to reproduce the bug

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions