Uploading my old custom logs to Google Cloud for AI analysis - impossible?

I'm trying to upload my old logs to gcloud for anomaly detection but it seems it isn't possible. I've tried AWS but they support uploading only 2 week old logs the oldest (wtf?). 

`gcloud logging write --payload-type=json` seems to be doing the trick, but it disregards the timestamp. How do I specify the timestamp field, or maybe in "Log Search" UI it would be possible to force-set timestamp field like it's possible in Kibana?...

Second question is how do run the anomaly detection, if that's possible at all?

All this is unrelated to gcloud per se, this is an external app.

2 1 108
1 REPLY 1

Hello @googleadmin1 ,

To specify the timestamp, you may need to include the timestamp field in your log entries to structure your JSOn payload to include the timestamp. Here is a sample:

{

"timestamp": "2024-03-07T12:00:00Z",

"message": "Log message content here"

}

To further utilize the anomaly detection, you may consider using machine learning models