added websocket and device configuration to this package#53
added websocket and device configuration to this package#53sligara7 wants to merge 3 commits intobluesky:mainfrom
Conversation
|
Thanks for this wonderfully detailed PR descrption, @sligara7. There is a lot to unpack in here. I think this package is a client library, a Python API to QueueServer's REST API. New server code may sit more comfortably in a different repository (the QueueServer repository?) But I'm missing buckets of context here, so I could be wrong. Looking forward to learning more. |
|
@danielballan, thanks for the quick comments, particularly on what should stay within the client side (bluesky_queueserver_api) versus moving to the server side (bluesky-queueserver)? Here are some recommendations (with the help of a LLM): ✅ KEEP in bluesky-queueserver-api:
❌ MOVE to bluesky-queueserver: Even though it provides "API" functionality, it's server-side API code (FastAPI routers), not client API code. The coordination service already imports and mounts these routes, confirming it's a server component. 📋 Final Structure: Move to bluesky-queueserver: Ultimately trying to have an interface between: Ophyd as a Service (https://github.com/bluesky/ophyd-websocket/tree/feature/oas) to create something like the following: Lots of architectural decisions to make about how to build this out, so looking forward to any recommendations you or anyone else may have. |
… the bluesky-queueserver package
This file should not have any changes in this PR as it only contains thread-based communication classes that are unchanged.
|
Reanalyzing the architecture, I think many features belong in different packages within the bluesky-ecosystem. Thanks for the comments. |


Summary of Changes
This update adds significant new functionality to the bluesky-queueserver-api, focusing on WebSocket communication, device coordination, and device configuration management. Here's a breakdown of the major additions:
1. WebSocket Support
ReManagerAPI_WS_Baseclass providing WebSocket functionalityws/with both sync (init.py) and async (aio.py) implementations2. Device Coordination Service (New Package:
coordination/)This is a complete new microservice for managing device access conflicts:
Key Features:
3. Device Configuration Management
4. Enhanced Package Structure
5. Integration Points
The changes enable better integration between:
6. Deployment and Usage
This update transforms the bluesky-queueserver-api from a simple HTTP/ZMQ client into a comprehensive ecosystem that supports real-time communication, device coordination, and conflict prevention across multiple services in the Bluesky environment.
Summary: React Queue Monitor
The new react_queue_monitor directory introduces a comprehensive React component library that provides web-based equivalents to the Qt-based Bluesky Queue Server monitoring and control interface. Here's a breakdown of what has been added:
Package Overview
@bluesky/react-queue-monitor- A complete React library for queue server interactionCore Components
1. Main Dashboard
2. Individual React Components (Qt equivalents)
StatusMonitor.tsx: Displays queue server status and connection stateRunningPlan.tsx: Displays currently executing plan detailsQueueControls.tsx: Start, stop, pause, resume queue operationsEnvironmentControls.tsx: Open, close, destroy RE environmentExecutionControls.tsx: Stop, abort, halt, pause, resume plan executionPlanEditor.tsx: Add and edit plans with parameter validation3. WebSocket Hook
4. Type Definitions
Key Features
Real-time Communication
Complete Functionality
Developer Experience
Usage Patterns
Integration Value
This React library enables:
The React Queue Monitor represents a complete port of the Qt-based queue monitoring functionality to the web, maintaining feature parity while leveraging modern React patterns and WebSocket real-time communication.