Closed diwanatharv closed 5 months ago
Hi @diwanatharv,
Thank you for using our client. It appears that you are looking to connect to InfluxDB Serverless, also referred to as InfluxDB 3. To ensure you have the best experience and compatibility, please use the dedicated client designed for InfluxDB 3, which you can find at InfluxDB 3 Go Client.
Should you have any questions while setting up or using this client, or if there's anything else we can assist you with, please don't hesitate to reach out.
Best Regards
Specifications
Steps to reproduce
i am not able to influxdb serverless using this package i am getting this everytime 2024/06/22 17:47:04 Error connecting to InfluxDB: invalid character '<' looking for beginning of value but when i am using the v3 the latest package that is kind of giving me correct output
func init() { err := godotenv.Load(".env") if err != nil { log.Fatalf("Error loading .env file") }
}
func NewInfluxDBClient(url, token string) influxdb.Client { client := influxdb.NewClient(url, token) _, err := client.Health(context.Background()) if err != nil { log.Fatalf("Error connecting to InfluxDB: %v", err) } return client }
Expected behavior
i am not able to influxdb serverless using this package i am getting this everytime 2024/06/22 17:47:04 Error connecting to InfluxDB: invalid character '<' looking for beginning of value but when i am using the v3 the latest package that is kind of giving me correct output
func init() { err := godotenv.Load(".env") if err != nil { log.Fatalf("Error loading .env file") }
}
func NewInfluxDBClient(url, token string) influxdb.Client { client := influxdb.NewClient(url, token) _, err := client.Health(context.Background()) if err != nil { log.Fatalf("Error connecting to InfluxDB: %v", err) } return client } please help me
Actual behavior
i am not able to influxdb serverless using this package i am getting this everytime 2024/06/22 17:47:04 Error connecting to InfluxDB: invalid character '<' looking for beginning of value but when i am using the v3 the latest package that is kind of giving me correct output
func init() { err := godotenv.Load(".env") if err != nil { log.Fatalf("Error loading .env file") }
}
func NewInfluxDBClient(url, token string) influxdb.Client { client := influxdb.NewClient(url, token) _, err := client.Health(context.Background()) if err != nil { log.Fatalf("Error connecting to InfluxDB: %v", err) } return client }
Additional info
No response