Abstract Internet of Things (IoT) jobs not only require computational resources but also are delay-sensitive and security-sensitive. Edge computing emerges as a promising paradigm to improve the quality of experience for IoT users. Edge computing faces many security threats, perhaps even more than traditional data centers. With a growing amount of data offloaded to Edge Data Centers (EDCs), the EDC performance needs to be considered and evaluated carefully for improving the vulnerable EDC resource utilization while satisfying IoT job requirements. This paper develops an analytical model, which can capture the dynamics of an EDC system with the following features: (i) The system is under heterogeneous workloads; (ii) the system is subject to attacks, which prevent equipment units in the system from providing service and (iii) the jobs in the system are delay-sensitive. Namely, the job processing fails before the processing is completed. Based on the proposed model, we develop formulas for performance and profit metrics and conduct a series of simulation experiments to verify the correctness and accuracy of our model. Finally, through our model, we evaluate the performance of the EDC, and we offer solutions for EDC administrators to maximize profit.