---
title: Unexpected value for Approximate Number Of Messages Not Visible
description: Understand why you may observe unexpected behavior from the Approximate Number Of Messages Not Visible attribute when used with the Change Message Visibility feature
tags: queues parameter visibility
dates:
  validation: 2025-05-28
  posted: 2025-05-28
---

## Unexpected value for Approximate Number Of Messages Not Visible

You may find that the `ChangeMessageVisibility` feature combined with the `ApproximateNumberOfMessagesNotVisible` attribute in Scaleway Queues does not behave as you expect.

When using `ChangeMessageVisibility` to set a `VisibilityTimeout` of `0`, you force the queue to requeue the message in question, making it immediately available for other consumers to process. You imagine this should have a direct effect on the `ApproximateNumberOfMessagesNotVisible` attribute, but the value for that attribute does not change.

## Cause 

The cause of the problem is that the underlying message broker used by Scaleway Queues does not provide the necessary information to set an absolutely correct value for the `ApproximateNumberOfMessagesNotVisible` attribute. As a result, this attribute does not accurately reflect the number of messages that are not visible.

## Solution 

We can confirm that the `ChangeMessageVisibility` feature works properly, and the name of the `ApproximateNumberOfMessagesNotVisible` attribute may be misleading. That said, the attribute name contains the qualifier "Approximate" for a reason, and as such its value may not always reflect the actual number of messages that are not visible.