diff --git a/broker/JFJochServices.cpp b/broker/JFJochServices.cpp
index d5cd1765..088a9d72 100644
--- a/broker/JFJochServices.cpp
+++ b/broker/JFJochServices.cpp
@@ -269,4 +269,10 @@ void JFJochServices::LoadDetectorPixelMask(PixelMask &mask) {
void JFJochServices::SetupIndexing(const IndexingSettings &input) {
if (receiver)
receiver->Indexing(input);
-}
\ No newline at end of file
+}
+
+uint64_t JFJochServices::GetConnectedWriters() const {
+ if (receiver)
+ return receiver->GetConnectedWriters();
+ return 0;
+}
diff --git a/broker/JFJochServices.h b/broker/JFJochServices.h
index 8e697184..22dc8b1c 100644
--- a/broker/JFJochServices.h
+++ b/broker/JFJochServices.h
@@ -67,6 +67,8 @@ public:
void LoadDetectorPixelMask(PixelMask &mask);
void SetupIndexing(const IndexingSettings& input);
+
+ uint64_t GetConnectedWriters() const;
};
diff --git a/broker/JFJochStateMachine.cpp b/broker/JFJochStateMachine.cpp
index 7092a98f..15d99777 100644
--- a/broker/JFJochStateMachine.cpp
+++ b/broker/JFJochStateMachine.cpp
@@ -554,6 +554,7 @@ BrokerStatus JFJochStateMachine::GetStatus() const {
ret.progress = services.GetReceiverProgress();
ret.gpu_count = gpu_count;
ret.broker_version = jfjoch_version();
+ ret.connected_writers = services.GetConnectedWriters();
return ret;
}
diff --git a/broker/OpenAPIConvert.cpp b/broker/OpenAPIConvert.cpp
index 84c78c0f..53159cef 100644
--- a/broker/OpenAPIConvert.cpp
+++ b/broker/OpenAPIConvert.cpp
@@ -242,6 +242,7 @@ org::openapitools::server::model::Broker_status Convert(const BrokerStatus& inpu
ret.setGpuCount(input.gpu_count);
ret.setBrokerVersion(input.broker_version);
+ ret.setConnectedWriters(input.connected_writers);
return ret;
}
diff --git a/broker/gen/model/Broker_status.cpp b/broker/gen/model/Broker_status.cpp
index 228da9cd..ef4a0640 100644
--- a/broker/gen/model/Broker_status.cpp
+++ b/broker/gen/model/Broker_status.cpp
@@ -32,6 +32,8 @@ Broker_status::Broker_status()
m_Gpu_countIsSet = false;
m_Broker_version = "";
m_Broker_versionIsSet = false;
+ m_Connected_writers = 0L;
+ m_Connected_writersIsSet = false;
}
@@ -73,7 +75,7 @@ bool Broker_status::validate(std::stringstream& msg, const std::string& pathPref
}
}
-
+
return success;
}
@@ -98,7 +100,10 @@ bool Broker_status::operator==(const Broker_status& rhs) const
((!gpuCountIsSet() && !rhs.gpuCountIsSet()) || (gpuCountIsSet() && rhs.gpuCountIsSet() && getGpuCount() == rhs.getGpuCount())) &&
- ((!brokerVersionIsSet() && !rhs.brokerVersionIsSet()) || (brokerVersionIsSet() && rhs.brokerVersionIsSet() && getBrokerVersion() == rhs.getBrokerVersion()))
+ ((!brokerVersionIsSet() && !rhs.brokerVersionIsSet()) || (brokerVersionIsSet() && rhs.brokerVersionIsSet() && getBrokerVersion() == rhs.getBrokerVersion())) &&
+
+
+ ((!connectedWritersIsSet() && !rhs.connectedWritersIsSet()) || (connectedWritersIsSet() && rhs.connectedWritersIsSet() && getConnectedWriters() == rhs.getConnectedWriters()))
;
}
@@ -122,6 +127,8 @@ void to_json(nlohmann::json& j, const Broker_status& o)
j["gpu_count"] = o.m_Gpu_count;
if(o.brokerVersionIsSet())
j["broker_version"] = o.m_Broker_version;
+ if(o.connectedWritersIsSet())
+ j["connected_writers"] = o.m_Connected_writers;
}
@@ -153,6 +160,11 @@ void from_json(const nlohmann::json& j, Broker_status& o)
j.at("broker_version").get_to(o.m_Broker_version);
o.m_Broker_versionIsSet = true;
}
+ if(j.find("connected_writers") != j.end())
+ {
+ j.at("connected_writers").get_to(o.m_Connected_writers);
+ o.m_Connected_writersIsSet = true;
+ }
}
@@ -249,6 +261,23 @@ void Broker_status::unsetBroker_version()
{
m_Broker_versionIsSet = false;
}
+int64_t Broker_status::getConnectedWriters() const
+{
+ return m_Connected_writers;
+}
+void Broker_status::setConnectedWriters(int64_t const value)
+{
+ m_Connected_writers = value;
+ m_Connected_writersIsSet = true;
+}
+bool Broker_status::connectedWritersIsSet() const
+{
+ return m_Connected_writersIsSet;
+}
+void Broker_status::unsetConnected_writers()
+{
+ m_Connected_writersIsSet = false;
+}
} // namespace org::openapitools::server::model
diff --git a/broker/gen/model/Broker_status.h b/broker/gen/model/Broker_status.h
index d5552c3e..3833dd4a 100644
--- a/broker/gen/model/Broker_status.h
+++ b/broker/gen/model/Broker_status.h
@@ -98,6 +98,13 @@ public:
void setBrokerVersion(std::string const& value);
bool brokerVersionIsSet() const;
void unsetBroker_version();
+ /// Idle, Error or
{- "detector_threshold_keV": 3.5,
- "frame_time_us": 10000,
- "number_of_frames": 1000,
- "max_allowed_pixel_count": 1,
- "max_frames_with_signal": 10
}[- {
- "pci_dev_id": "string",
- "serial_number": "string",
- "fw_version": "string",
- "base_mac_addr": "string",
- "eth_link_count": 0,
- "eth_link_status": 0,
- "power_usage_W": 0.1,
- "fpga_temp_C": 0.1,
- "hbm_temp_C": 0.1,
- "packets_udp": 0,
- "packets_sls": 0,
- "idle": true,
- "pcie_link_speed": 0,
- "pcie_link_width": 0
}
]Return array of XFEL pulse IDs - (-1) if image not recorded
{- "box": {
- "rois": [
- {
- "name": "string",
- "min_x_pxl": 0,
- "max_x_pxl": 0,
- "min_y_pxl": 0,
- "max_y_pxl": 0
}
]
}, - "circle": {
- "rois": [
- {
- "name": "string",
- "center_x_pxl": 0.1,
- "center_y_pxl": 0.1,
- "radius_pxl": 0.1
}
]
}, - "azim": {
- "rois": [
- {
- "name": "string",
- "q_min_recipA": 0.00001,
- "q_max_recipA": 0.00001
}
]
}
}{- "msg": "Detector in wrong state",
- "reason": "WrongDAQState"
}| compression | boolean Default: false Enable DEFLATE compression of output data. |
{- "detector": {
- "state": "Idle",
- "powerchip": "PowerOn",
- "server_version": "string",
- "number_of_triggers_left": 0,
- "fpga_temp_degC": [
- 0
], - "high_voltage_V": [
- 0
]
}, - "detector_list": {
- "detectors": [
- {
- "id": 0,
- "description": "JUNGFRAU 4 Mpixel",
- "serial_number": "JF17T16V01",
- "base_ipv4_addr": "10.10.10.1",
- "udp_interface_count": 2,
- "nmodules": 18,
- "width": 2068,
- "height": 2164,
- "pixel_size_mm": 0.075,
- "readout_time_us": 0,
- "min_frame_time_us": 0,
- "min_count_time_us": 0,
- "type": "EIGER"
}
], - "current_id": 0
}, - "detector_settings": {
- "frame_time_us": 1,
- "count_time_us": 0,
- "internal_frame_generator": false,
- "internal_frame_generator_images": 1,
- "detector_trigger_delay_ns": 0,
- "timing": "auto",
- "eiger_threshold_keV": 1,
- "eiger_bit_depth": 8,
- "jungfrau_pedestal_g0_frames": 2000,
- "jungfrau_pedestal_g1_frames": 300,
- "jungfrau_pedestal_g2_frames": 300,
- "jungfrau_pedestal_min_image_count": 128,
- "jungfrau_storage_cell_count": 1,
- "jungfrau_storage_cell_delay_ns": 5000,
- "jungfrau_fixed_gain_g1": false,
- "jungfrau_use_gain_hg0": false
}, - "image_format_settings": {
- "summation": true,
- "geometry_transform": true,
- "jungfrau_conversion": true,
- "jungfrau_conversion_factor_keV": 0.001,
- "bit_depth_image": 8,
- "signed_output": true,
- "mask_module_edges": true,
- "mask_chip_edges": true,
- "jungfrau_mask_pixels_without_g0": true,
- "apply_mask": false,
- "jungfrau_pedestal_g0_rms_limit": 100
}, - "instrument_metadata": {
- "source_name": "Swiss Light Source",
- "source_type": "Synchrotron X-ray Source",
- "instrument_name": "CristallinaMX",
- "pulsed_source": false,
- "electron_source": false
}, - "file_writer_settings": {
- "overwrite": false,
- "format": "None"
}, - "data_processing_settings": {
- "enable": true,
- "indexing": true,
- "signal_to_noise_threshold": 0.1,
- "photon_count_threshold": 0,
- "min_pix_per_spot": 1,
- "max_pix_per_spot": 1,
- "high_resolution_limit": 0.1,
- "low_resolution_limit": 0.1,
- "high_resolution_limit_for_spot_count_low_res": 2,
- "quick_integration": false,
- "ice_ring_width_q_recipA": 0.02,
- "high_res_gap_Q_recipA": 1.5
}, - "measurement": {
- "file_prefix": "string",
- "run_number": 0,
- "experiment_group": "string",
- "images_expected": 0,
- "images_collected": 0,
- "images_sent": 0,
- "images_written": 0,
- "images_discarded_lossy_compression": 0,
- "max_image_number_sent": 0,
- "collection_efficiency": 1,
- "compression_ratio": 5.3,
- "cancelled": true,
- "max_receiver_delay": 0,
- "indexing_rate": 0.1,
- "detector_width": 0,
- "detector_height": 0,
- "detector_pixel_depth": 2,
- "bkg_estimate": 0.1,
- "unit_cell": "string",
- "error_pixels": 0.1,
- "saturated_pixels": 0.1,
- "roi_beam_pixels": 0.1,
- "roi_beam_sum": 0.1
}, - "broker": {
- "state": "Inactive",
- "progress": 1,
- "message": "string",
- "message_severity": "success",
- "gpu_count": 0,
- "broker_version": "1.0.0-rc.128"
}, - "fpga": [
- {
- "pci_dev_id": "string",
- "serial_number": "string",
- "fw_version": "string",
- "base_mac_addr": "string",
- "eth_link_count": 0,
- "eth_link_status": 0,
- "power_usage_W": 0.1,
- "fpga_temp_C": 0.1,
- "hbm_temp_C": 0.1,
- "packets_udp": 0,
- "packets_sls": 0,
- "idle": true,
- "pcie_link_speed": 0,
- "pcie_link_width": 0
}
], - "calibration": [
- {
- "module_number": 0,
- "storage_cell_number": 0,
- "pedestal_g0_mean": 0.1,
- "pedestal_g1_mean": 0.1,
- "pedestal_g2_mean": 0.1,
- "gain_g0_mean": 0.1,
- "gain_g1_mean": 0.1,
- "gain_g2_mean": 0.1,
- "masked_pixels": 0
}
], - "zeromq_preview": {
- "enabled": true,
- "period_ms": 1000,
- "socket_address": "string"
}, - "zeromq_metadata": {
- "enabled": true,
- "period_ms": 1000,
- "socket_address": "string"
}, - "dark_mask": {
- "detector_threshold_keV": 3.5,
- "frame_time_us": 10000,
- "number_of_frames": 1000,
- "max_allowed_pixel_count": 1,
- "max_frames_with_signal": 10
}, - "pixel_mask": {
- "user_mask": 0,
- "too_high_pedestal_rms": 0,
- "wrong_gain": 0
}, - "roi": {
- "box": {
- "rois": [
- {
- "name": "string",
- "min_x_pxl": 0,
- "max_x_pxl": 0,
- "min_y_pxl": 0,
- "max_y_pxl": 0
}
]
}, - "circle": {
- "rois": [
- {
- "name": "string",
- "center_x_pxl": 0.1,
- "center_y_pxl": 0.1,
- "radius_pxl": 0.1
}
]
}, - "azim": {
- "rois": [
- {
- "name": "string",
- "q_min_recipA": 0.00001,
- "q_max_recipA": 0.00001
}
]
}
}, - "az_int": {
- "polarization_corr": true,
- "solid_angle_corr": true,
- "high_q_recipA": 0.1,
- "low_q_recipA": 0.1,
- "q_spacing": 0.1,
- "azimuthal_bins": 1
}, - "buffer": {
- "min_image_number": 0,
- "max_image_number": 0,
- "image_numbers": [
- 0
], - "total_slots": 0,
- "available_slots": 0,
- "in_preparation_slots": 0,
- "in_sending_slots": 0,
- "current_counter": 0
}, - "indexing": {
- "algorithm": "FFBIDX",
- "fft_max_unit_cell_A": 250,
- "fft_min_unit_cell_A": 10,
- "fft_high_resolution_A": 2,
- "fft_num_vectors": 16384,
- "tolerance": 0.5,
- "thread_count": 1,
- "geom_refinement_algorithm": "BeamCenter",
- "unit_cell_dist_tolerance": 0.05,
- "viable_cell_min_spots": 10,
- "index_ice_rings": false,
- "rotation_indexing": false,
- "rotation_indexing_min_angular_range_deg": 20,
- "rotation_indexing_angular_stride_deg": 0.5
}
}{- "detector": {
- "state": "Idle",
- "powerchip": "PowerOn",
- "server_version": "string",
- "number_of_triggers_left": 0,
- "fpga_temp_degC": [
- 0
], - "high_voltage_V": [
- 0
]
}, - "detector_list": {
- "detectors": [
- {
- "id": 0,
- "description": "JUNGFRAU 4 Mpixel",
- "serial_number": "JF17T16V01",
- "base_ipv4_addr": "10.10.10.1",
- "udp_interface_count": 2,
- "nmodules": 18,
- "width": 2068,
- "height": 2164,
- "pixel_size_mm": 0.075,
- "readout_time_us": 0,
- "min_frame_time_us": 0,
- "min_count_time_us": 0,
- "type": "EIGER"
}
], - "current_id": 0
}, - "detector_settings": {
- "frame_time_us": 1,
- "count_time_us": 0,
- "internal_frame_generator": false,
- "internal_frame_generator_images": 1,
- "detector_trigger_delay_ns": 0,
- "timing": "auto",
- "eiger_threshold_keV": 1,
- "eiger_bit_depth": 8,
- "jungfrau_pedestal_g0_frames": 2000,
- "jungfrau_pedestal_g1_frames": 300,
- "jungfrau_pedestal_g2_frames": 300,
- "jungfrau_pedestal_min_image_count": 128,
- "jungfrau_storage_cell_count": 1,
- "jungfrau_storage_cell_delay_ns": 5000,
- "jungfrau_fixed_gain_g1": false,
- "jungfrau_use_gain_hg0": false
}, - "image_format_settings": {
- "summation": true,
- "geometry_transform": true,
- "jungfrau_conversion": true,
- "jungfrau_conversion_factor_keV": 0.001,
- "bit_depth_image": 8,
- "signed_output": true,
- "mask_module_edges": true,
- "mask_chip_edges": true,
- "jungfrau_mask_pixels_without_g0": true,
- "apply_mask": false,
- "jungfrau_pedestal_g0_rms_limit": 100
}, - "instrument_metadata": {
- "source_name": "Swiss Light Source",
- "source_type": "Synchrotron X-ray Source",
- "instrument_name": "CristallinaMX",
- "pulsed_source": false,
- "electron_source": false
}, - "file_writer_settings": {
- "overwrite": false,
- "format": "None"
}, - "data_processing_settings": {
- "enable": true,
- "indexing": true,
- "signal_to_noise_threshold": 0.1,
- "photon_count_threshold": 0,
- "min_pix_per_spot": 1,
- "max_pix_per_spot": 1,
- "high_resolution_limit": 0.1,
- "low_resolution_limit": 0.1,
- "high_resolution_limit_for_spot_count_low_res": 2,
- "quick_integration": false,
- "ice_ring_width_q_recipA": 0.02,
- "high_res_gap_Q_recipA": 1.5
}, - "measurement": {
- "file_prefix": "string",
- "run_number": 0,
- "experiment_group": "string",
- "images_expected": 0,
- "images_collected": 0,
- "images_sent": 0,
- "images_written": 0,
- "images_discarded_lossy_compression": 0,
- "max_image_number_sent": 0,
- "collection_efficiency": 1,
- "compression_ratio": 5.3,
- "cancelled": true,
- "max_receiver_delay": 0,
- "indexing_rate": 0.1,
- "detector_width": 0,
- "detector_height": 0,
- "detector_pixel_depth": 2,
- "bkg_estimate": 0.1,
- "unit_cell": "string",
- "error_pixels": 0.1,
- "saturated_pixels": 0.1,
- "roi_beam_pixels": 0.1,
- "roi_beam_sum": 0.1
}, - "broker": {
- "state": "Inactive",
- "progress": 1,
- "message": "string",
- "message_severity": "success",
- "gpu_count": 0,
- "broker_version": "1.0.0-rc.128",
- "connected_writers": 0
}, - "fpga": [
- {
- "pci_dev_id": "string",
- "serial_number": "string",
- "fw_version": "string",
- "base_mac_addr": "string",
- "eth_link_count": 0,
- "eth_link_status": 0,
- "power_usage_W": 0.1,
- "fpga_temp_C": 0.1,
- "hbm_temp_C": 0.1,
- "packets_udp": 0,
- "packets_sls": 0,
- "idle": true,
- "pcie_link_speed": 0,
- "pcie_link_width": 0
}
], - "calibration": [
- {
- "module_number": 0,
- "storage_cell_number": 0,
- "pedestal_g0_mean": 0.1,
- "pedestal_g1_mean": 0.1,
- "pedestal_g2_mean": 0.1,
- "gain_g0_mean": 0.1,
- "gain_g1_mean": 0.1,
- "gain_g2_mean": 0.1,
- "masked_pixels": 0
}
], - "zeromq_preview": {
- "enabled": true,
- "period_ms": 1000,
- "socket_address": "string"
}, - "zeromq_metadata": {
- "enabled": true,
- "period_ms": 1000,
- "socket_address": "string"
}, - "dark_mask": {
- "detector_threshold_keV": 3.5,
- "frame_time_us": 10000,
- "number_of_frames": 1000,
- "max_allowed_pixel_count": 1,
- "max_frames_with_signal": 10
}, - "pixel_mask": {
- "user_mask": 0,
- "too_high_pedestal_rms": 0,
- "wrong_gain": 0
}, - "roi": {
- "box": {
- "rois": [
- {
- "name": "string",
- "min_x_pxl": 0,
- "max_x_pxl": 0,
- "min_y_pxl": 0,
- "max_y_pxl": 0
}
]
}, - "circle": {
- "rois": [
- {
- "name": "string",
- "center_x_pxl": 0.1,
- "center_y_pxl": 0.1,
- "radius_pxl": 0.1
}
]
}, - "azim": {
- "rois": [
- {
- "name": "string",
- "q_min_recipA": 0.00001,
- "q_max_recipA": 0.00001
}
]
}
}, - "az_int": {
- "polarization_corr": true,
- "solid_angle_corr": true,
- "high_q_recipA": 0.1,
- "low_q_recipA": 0.1,
- "q_spacing": 0.1,
- "azimuthal_bins": 1
}, - "buffer": {
- "min_image_number": 0,
- "max_image_number": 0,
- "image_numbers": [
- 0
], - "total_slots": 0,
- "available_slots": 0,
- "in_preparation_slots": 0,
- "in_sending_slots": 0,
- "current_counter": 0
}, - "indexing": {
- "algorithm": "FFBIDX",
- "fft_max_unit_cell_A": 250,
- "fft_min_unit_cell_A": 10,
- "fft_high_resolution_A": 2,
- "fft_num_vectors": 16384,
- "tolerance": 0.5,
- "thread_count": 1,
- "geom_refinement_algorithm": "BeamCenter",
- "unit_cell_dist_tolerance": 0.05,
- "viable_cell_min_spots": 10,
- "index_ice_rings": false,
- "rotation_indexing": false,
- "rotation_indexing_min_angular_range_deg": 20,
- "rotation_indexing_angular_stride_deg": 0.5
}
}