func NewThinInfluxClient(server string, port int, database, username, password, precision string, ssl bool) (ThinInfluxClient, error) {
	errormessage := ""
	if len(server) == 0 {
		errormessage = "No url indicated"
	}
	if port < 1000 || port > 65535 {
		errormessage = "Port not in acceptable range"
	}
	if len(database) == 0 {
		errormessage = "No database indicated"
	}
	found := false
	for _, p := range precisions {
		if p == precision {
			found = true
			break
		}
	}
	if !found {
		errormessage = "Precision '" + precision + "' not in supported presisions " + strings.Join(precisions, ",")
	}
	fullurl := "http"
	if ssl {
		fullurl += "s"
	}
	if len(errormessage) > 0 {
		return ThinInfluxClient{}, errors.New(errormessage)
	}
	fullurl += "://" + server + ":" + strconv.Itoa(port) + "/write?db=" + database + "&precision=" + precision
	return ThinInfluxClient{URL: fullurl, Username: username, password: password}, nil
}
NewThinInfluxClient creates a new thin influx client
package thininfluxclient
import (
	"bytes"
	"compress/gzip"
	"errors"
	"io"
	"io/ioutil"
	"net/http"
	"strconv"
	"strings"
	json "github.com/pquerna/ffjson/ffjson"
)
var precisions = []string{"ns", "u", "ms", "s", "m", "h"}
var maxlines = 5000
type InfluxError struct {
	Error string
}
type ThinInfluxClient struct {
	URL      string
	Username string
	password string
}