refactor for discrete ops and integration tests
fixes aplenty plus better influxdb support