Amazon sells compute, and that's always needed for this sort of thing. They may develop new AI accelerator stacks (including racked hardware) in the future as well, so sure. I don't want to be one of those "the Internet is a fad" people, but I'm absolutely not telling you do do anything rash, go do your own research. Even if you bet at well as you can, the dot-com crash wiped people like you out, and that's assuming you get the general picture right.
> how can I ensure my economic status will not be affected?
You cannot.
It sucks, but it's inevitable. The same thing has been happening ever since the industrial revolution. Old skills become obsolete, and nobody cares what happens to people who've invested their entire lives into something that is no longer profitable.
How can you ensure your economic status will not be affected?
How were farriers able to ensure their economic status wasn't affected by cars?
How were switchboard operators able to ensure their economic status wasn't affected by automatic switching?
How were travel agents able to ensure their economic status wasn't affected by Expedia, Priceline, and the dozen other sites out there?
No one can know when or how their job is going to go extinct. You just need to pay attention to the changing winds of technology and adjust your ship's sail accordingly.