Sensor based water quality monitoring system