I lost a draft post in Voyager on Android while I was a few apps away doing research and looking for a photo to add to the post.

That brought to me an understanding that Android will just kill apps for memory purposes.

Then I thought back to Windows 98 and how it had a page file that would write RAM information to the hard disk and use it as RAM. It was slow af, but it worked.

So I’m wondering: it’s 2026; why is Android just killing apps instead of writing them to a much faster drive for recall when needed?

  • affenlehrer@feddit.org
    link
    fedilink
    arrow-up
    27
    ·
    17 hours ago

    When you develop an Android app it follows a defined lifecycle. The app is notified about changing states and is supposed to persist it’s data in some of them. So ideally you wouldn’t even notice that the app was killed since it would continue exactly where it was killed.

    • owenfromcanada@lemmy.ca
      link
      fedilink
      arrow-up
      11
      ·
      17 hours ago

      This is it, and it’s arguably a much better model. Apps are able to manage their own persistent storage, and you can always be sure that your RAM is actually RAM (and not deal with the speed and timing issues that result in you “RAM” actually being flash memory).

      • Ephera@lemmy.ml
        link
        fedilink
        arrow-up
        3
        ·
        13 hours ago

        Problem is that it’s not at all trivial to implement, so it often isn’t implemented.

        • owenfromcanada@lemmy.ca
          link
          fedilink
          arrow-up
          1
          ·
          12 hours ago

          That’s true. But it’s also not trivial to implement an app that may have its “RAM” located on disk. It’s a complex problem with multiple solutions, and giving apps the freedom to do what they want with it is the way Android structured things.

      • bazsy@lemmy.world
        link
        fedilink
        arrow-up
        14
        ·
        15 hours ago

        That’s because voyager is a web app. It is a well designed and integrated PWA which makes it look and feel close to a native mobile app. The above mentioned preferred solution is Android specific and many multiplatform apps skip such optimization.