Azure / azure-storage-java

Microsoft Azure Storage Library for Java
https://docs.microsoft.com/en-us/java/api/overview/azure/storage
MIT License
189 stars 165 forks source link

Azure-Storage SDK 8.6.5 giving exceptions while iterating #579

Open nikhilMS123 opened 1 year ago

nikhilMS123 commented 1 year ago

Which service(blob, file, queue, table) does this issue concern?

table

Which version of the SDK was used?

8.6.5

What problem was encountered?

Unable to iterate over a set of results. Following is the exception: Caused by: java.util.NoSuchElementException: An error occurred while enumerating the result, check the original exception for details. at com.microsoft.azure.storage.core.LazySegmentedIterator.hasNext(LazySegmentedIterator.java:113)

The code was something like this:
Iterable<PEntity> results = (Iterable<PEntity>)
            this.TableStore.queryByKey(PEntity.class,
                    ROW_KEY, ID);
    for (PEntity tableEntity : results) {                           // From here it raised exception
        partitions.add(tableEntity.getKey());
    }

    The exception occured in For loop 

Have you found a mitigation/solution?

No.