Transparent remote object proxying
Project description
Invisibles
Transparent remote method invocation. Same object, same usage, different location.
What It Does
You have an object. You want to move it to another process, another node. The code that uses it doesn't change.
# Local
result = service.add(5, 3)
data = await service.fetch("key")
# Remote - identical
result = proxy.add(5, 3)
data = await proxy.fetch("key")
Sync methods stay sync. Async methods stay async. The proxy matches the remote object's API exactly.
Architecture
Two connection channels, each doing what it's good at:
- Sync connection - reentrant serving pattern, handles sync methods and protocol operations
- Async connection - message pump with asyncio futures, handles async methods natively
Both share a Protocol instance that manages boxing, dispatch, and proxy creation. See docs/architecture.md for details.
Key Concepts
- Service - any Python object exposed remotely, no base class needed
- Connection - per-client RPC channel (sync or async), wraps netkit transport
- Proxy - client-side transparent handle, created automatically during unboxing
- Protocol - shared RPC state: boxing, dispatch, object registry, proxy caching
- Dispatcher - how sync method calls are run (inline, threaded, or shared)
Deployment Scenarios
| Object type | Clients | Execution | Setup |
|---|---|---|---|
| Sync, not thread-safe | Single | Serialized | SyncServer + InlineDispatcher |
| Sync, not thread-safe | Multiple | Serialized | SyncServer + SharedDispatcher |
| Sync, thread-safe | Multiple | Parallel | SyncServer + ThreadedDispatcher |
| Async / Mixed | Any | Async on server loop | SyncServer + AsyncDispatcher |
See docs/scenarios.md for the full matrix.
Python Protocol Support
Works transparently over RPC:
- Method calls (sync and async)
- Attribute access
- Iterators and generators (
for x in proxy) - Async iterators (
async for x in proxy) - Context managers (
with proxy) - Async context managers (
async with proxy) - Operator overloading (
+,-,*,[],in,len, etc.) - Callable objects (
proxy(args)) - Exception propagation (including custom exception classes)
- Nested objects (methods returning objects that are themselves proxied)
Docs
- docs/overview.md - execution model and design rationale
- docs/architecture.md - concepts, flow diagrams, boxing
- docs/scenarios.md - deployment scenarios matrix
- docs/netkit.md - networking layer (vendored)
License
Apache-2.0 - See LICENSE.md
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file invisibles_py-0.1.0.tar.gz.
File metadata
- Download URL: invisibles_py-0.1.0.tar.gz
- Upload date:
- Size: 97.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
77401a37fd4e8b82e8ce31d69bb2f03a5c2472a5e8c85d9d472ccf13ca977a6a
|
|
| MD5 |
6c170f3b8e70dd2b4c59e8b183179579
|
|
| BLAKE2b-256 |
a6577fb130a327faa3dcfdf40402e94639e9c791c93838b7979380fda4b5ee41
|
Provenance
The following attestation bundles were made for invisibles_py-0.1.0.tar.gz:
Publisher:
publish.yml on nustackdev/invisibles
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
invisibles_py-0.1.0.tar.gz -
Subject digest:
77401a37fd4e8b82e8ce31d69bb2f03a5c2472a5e8c85d9d472ccf13ca977a6a - Sigstore transparency entry: 2148905576
- Sigstore integration time:
-
Permalink:
nustackdev/invisibles@2bbaf823fda2ee7053d041cf699663af1259f160 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/nustackdev
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2bbaf823fda2ee7053d041cf699663af1259f160 -
Trigger Event:
push
-
Statement type:
File details
Details for the file invisibles_py-0.1.0-py3-none-any.whl.
File metadata
- Download URL: invisibles_py-0.1.0-py3-none-any.whl
- Upload date:
- Size: 78.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0383de804a300972848ea7e9caaa2d1308ba661c9fda17fba26cbdd73655e1c0
|
|
| MD5 |
099f8464a3de45495fde424f36e0f8ac
|
|
| BLAKE2b-256 |
1f7d301d3295e1cf211355e0f1a2dd2b8344e77861cac9f6e87efc1921bf9485
|
Provenance
The following attestation bundles were made for invisibles_py-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on nustackdev/invisibles
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
invisibles_py-0.1.0-py3-none-any.whl -
Subject digest:
0383de804a300972848ea7e9caaa2d1308ba661c9fda17fba26cbdd73655e1c0 - Sigstore transparency entry: 2148905644
- Sigstore integration time:
-
Permalink:
nustackdev/invisibles@2bbaf823fda2ee7053d041cf699663af1259f160 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/nustackdev
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2bbaf823fda2ee7053d041cf699663af1259f160 -
Trigger Event:
push
-
Statement type: