A controller, configured to: obtain a state of each of a plurality of queues of a network node, wherein the state of a queue is indicative of a utilization of the queue, and wherein each queue is associated with a priority entry; determine, based on the states of the queues, whether the utilization of one or more queues exceeds one or more thresholds, wherein one threshold is associated with each of the plurality of queues, wherein the one or more thresholds comprises a first threshold indicative of a nearly full state of a queue; generate one or more new priority entries for one or more queues of the plurality of queues, if one or more thresholds are exceeded; and provide the one or more new priority entries to the one or more queues of the network node, wherein the controller is further configured to: determine that the utilization of one or more queues exceeds the one or more thresholds, if a quantity of frames in the queue exceeds the first threshold; and determine one or more first queues from the plurality of queues, wherein for each of the one or more first queues the quantity of frames exceeds the first threshold, determine one or more second queues from the plurality of queues, based on one or more default priority entries of the one or more second queues, wherein a default priority entry of each of the one or more second queues is lower than a respective default priority entry of one of the one or more first queues, and generate one or more new priority entries for the one or more first queues, wherein each of the generated one or more priority entries of the one or more first queues equals to a respective default priority entry of one of the one or more second queues. obtain a state of each of a plurality of queues of a network node, wherein the state of a queue is indicative of a utilization of the queue, and wherein each queue is associated with a priority entry; determine, based on the states of the queues, whether the utilization of one or more queues exceeds one or more thresholds, wherein one threshold is associated with each of the plurality of queues, wherein the one or more thresholds comprises a first threshold indicative of a nearly full state of a queue; generate one or more new priority entries for one or more queues of the plurality of queues, if one or more thresholds are exceeded; and provide the one or more new priority entries to the one or more queues of the network node, wherein the controller is further configured to: determine that the utilization of one or more queues exceeds the one or more thresholds, if a quantity of frames in the queue exceeds the first threshold; and determine one or more first queues from the plurality of queues, wherein for each of the one or more first queues the quantity of frames exceeds the first threshold, determine one or more second queues from the plurality of queues, based on one or more default priority entries of the one or more second queues, wherein a default priority entry of each of the one or more second queues is lower than a respective default priority entry of one of the one or more first queues, and generate one or more new priority entries for the one or more first queues, wherein each of the generated one or more priority entries of the one or more first queues equals to a respective default priority entry of one of the one or more second queues. determine that the utilization of one or more queues exceeds the one or more thresholds, if a quantity of frames in the queue exceeds the first threshold; and determine one or more first queues from the plurality of queues, wherein for each of the one or more first queues the quantity of frames exceeds the first threshold, determine one or more second queues from the plurality of queues, based on one or more default priority entries of the one or more second queues, wherein a default priority entry of each of the one or more second queues is lower than a respective default priority entry of one of the one or more first queues, and generate one or more new priority entries for the one or more first queues, wherein each of the generated one or more priority entries of the one or more first queues equals to a respective default priority entry of one of the one or more second queues.