Inode/Hits

Good day everyone !

So my site is hosted here for about ~10 months now, and I’ve just updated it.
I moved my old site files into folder named v1, then on the root directory of htdocs is where my updated files reside.

The changes I implemented are the following:

  • downloaded bootstrap, jquery, swal2, etc. and saved it on a folder named Assets.
  • make a lot of ajax request in the background ( mainly for infinite scrolling ).
  • refactored my model and controller functions. (created model for each one of mysql tables so more files)

Here’s my concern

  • Does making bootstrap, jquery, and other css/js that are available using CDN counts in inode/hits?
  • Does my old files, while not even part of my v2 route, also registers a hit/inode ?
  • Should I lessen my ajax requests ?

here’s my directory structure
/ (htdocs)
β”œβ”€β”€ v1/
β”‚ β”œβ”€β”€ uploads/
β”‚ β”œβ”€β”€ attachments/
β”‚ β”œβ”€β”€ models/
β”‚ β”œβ”€β”€ controllers/
β”‚ β”œβ”€β”€ views/
β”‚ β”œβ”€β”€ files1.php
β”‚ β”œβ”€β”€ files2.php
β”‚ β”œβ”€β”€ files3.php
β”‚ β”œβ”€β”€ files4.php
β”‚ └── files5.php
β”œβ”€β”€ assets/
β”œβ”€β”€ uploads/
β”œβ”€β”€ attachments/
β”œβ”€β”€ models/
β”œβ”€β”€ controllers/
β”œβ”€β”€ views/
β”œβ”€β”€ index.php
β”œβ”€β”€ landing.php
β”œβ”€β”€ files3.php
β”œβ”€β”€ files4.php
└── files5.php … etc.

Sorry for any grammatical errors. I hope you understand what Im trying to tell :slight_smile:
Answers and recommendations are appreciated. Thanks !

It depends on how the CDN works exactly.

If the files are uploaded from your site to the CDN, served entirely from the CDN, and the files don’t exist on your hosting account, then no hits or inodes will be used on your account, because all hits and inodes are handled by the CDN provider.

If the CDN simply fetches the files from your website with us, and caches and redistributes the files, then it will help to reduce your hits usage for these files (but not eliminate it, the CDN still needs to get the files from your website), and it won’t help with inodes at all (because the files need to be stored all the same).

Inodes are the files and directories on your account. So all files on your account, even the ones which are not used, count against your inode usage.

Hits used is caused by web traffic. If the v1 files are never accessed, then they will not generate any hits usage.

That’s impossible to tell.

AJAX in itself is not evil. For your hits usage, it really doesn’t matter if you have infinite scrolling with AJAX or just a paginated list where you just navigate to the next page using plain HTML links.

As long as you don’t do anything obviously stupid, like code that constantly refreshes in the background, or fetches tiny scraps of data from the backend with a large number of requests, you don’t need to worry too much.

4 Likes

oohhh I see, it’s all clear now. thanks a lot.

1 Like