Skip to content

Asyncio Module VectorCollection Support [5/6]#751

Merged
yuce merged 77 commits into
hazelcast:masterfrom
yuce:asyncio-module-vc-support
Dec 5, 2025
Merged

Asyncio Module VectorCollection Support [5/6]#751
yuce merged 77 commits into
hazelcast:masterfrom
yuce:asyncio-module-vc-support

Conversation

@yuce

@yuce yuce commented Nov 19, 2025

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread hazelcast/internal/asyncio_proxy/vector_collection.py
Comment thread hazelcast/internal/asyncio_proxy/vector_collection.py
Comment thread hazelcast/internal/asyncio_reactor.py Outdated

class AsyncioReactor:
def __init__(self, loop: AbstractEventLoop | None = None):
self._is_live = False

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this not needed anymore?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was never used, so removed it.

@yuce yuce changed the title [DON'T MERGE] Asyncio Module VectorCollection Support [5/6] Asyncio Module VectorCollection Support [5/6] Dec 4, 2025
# Conflicts:
#	hazelcast/internal/asyncio_connection.py
#	hazelcast/internal/asyncio_reactor.py

async def asyncTearDown(self):
await self.vector_collection.destroy()
await super().asyncTearDown()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how come we do not have similar line to super class call for the asyncore test?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SingleMemberTestCase derives from unittest.IsolatedAsyncioTestCase.
unittest.IsolatedAsyncioTestCase doesn't do anything in its asyncSetUp or asyncTearDown, so calling super() is not necessary for the tests that derive from unittest.IsolatedAsyncioTestCase.

SingleMemberTestCase does things in asyncSetUporasyncTearDown, so the test classes that derive from it must call super()`.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like we instantiate new client per each test case in asyncio version of the test and in the asyncore version instantiate per class. We may want to make the two test similar for long ter maintenance.

@yuce
yuce merged commit 11d001d into hazelcast:master Dec 5, 2025
11 checks passed
@yuce
yuce deleted the asyncio-module-vc-support branch December 5, 2025 02:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants