If we are to deploy sensor applications in a realistic business context, we must provide innovative middleware services to control and enforce required system behavior. Sensor application developers typically reason about required system behavior in terms of high-level quality goals. Due to the extreme dynamism, scale and unreliability of wireless sensor networks, managing these goals using contemporary software management techniques without support for high-level quality goals quickly becomes challenging. This paper presents QARI, a middleware service which addresses these management challenges by offering a simple yet flexible way to define, enforce, and maintain high-level quality goals for software deployment in wireless sensor networks. We have evaluated QARI using the LooCI component model on two sensor node platforms; results confirm that QARI enables quality aware software deployment for a single application as well as multiple applications, and even in the presence of node failure and mobility.