Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question Any way to inspect the contents of the accelerator server?

Discussion in 'Unity Accelerator' started by jamie_xr, Jan 9, 2023.

  1. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    54
    Most of the issues we have around accelerator comes down to "Is that asset cached or not?" Quite often it's not and we have to trigger reimport to get it to upload.

    I'd like to know if there is an api to ping the server to see if the asset exists in cache or not, and if not then we can upload it ourselves ideally. It must exist since unity must be using this to query the cache itself. However it's not documented. Why not open this api up for everyone to use. It would be quite quick to make a debug window showing which assets are in cache and which are not.
     
  2. cdr9042

    cdr9042

    Joined:
    Apr 22, 2018
    Posts:
    148
    If you don't mind, can you tell me the reason for checking if it's cached or not? I've just started using Unity Accelerator. As I understand it, the process is automatic, if the client does not have the file, then it will request the server to download that file and then store it on the server, then send it to the client.
     
  3. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    54
    We have had a lot of issues with corrupted caches and other such things like packages not caching properly. Also it won't automatically upload it. You have to manually reimport an asset to get it to upload to the cache. I may want to upload any uncached assets rather than reimport the whole project. I think it would just be a useful tool for debugging these kinda issues
     
  4. unity_Jonny

    unity_Jonny

    Unity Technologies

    Joined:
    Feb 11, 2020
    Posts:
    13
    The unity-accelerator command line tool has a lot of usefull sub commands you can use to interact with a running accelerator instance.
    You can query for cached keys, clear individual keys or whole namespaces and lots more. Run the tool with no args and check the usage instructions
     
  5. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    54
    I've used this quite a bit just for purging corrupted caches and such.
    Is there a way to get the key of an asset inside unity? It's not as simple as it's asset guid. If so I can make some tools to check by using the cli tool to check individual assets
     
  6. cdr9042

    cdr9042

    Joined:
    Apr 22, 2018
    Posts:
    148
    what could possibly cause corrupt cache in the first place? Do you use old hard drive or wrong drive format? I used to use exFAT drive format for Unity projects and it caused a lot of errors so I reformatted the drive to Mac OS Extended and it fixed the errors.