1. A method, comprising: determining, via data processing circuitry, error rate metrics of data transmissions over a constrained application protocol (CoAP) using a first CoAP segment size; determining, via the data processing circuitry, a second CoAP segment size for the data transmissions based at least in part upon the error rate metrics; wherein determining the error rate metrics comprises determining a current error rate of the data transmissions and determining a historical average of error rates of the data transmissions and wherein determining the second CoAP segment size comprises: weighting the current error rate to obtain a weighted current error rate; weighting the historical average of error rates to obtain a weighted average; summing the weighted current error rate and the weighted historical average to obtain a manipulated variable; and correlating the manipulated variable with a corresponding CoAP segment size to obtain the second CoAP segment size.