v0.1.0-pre.014
This commit is contained in:
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/dflow_aggregator_v4.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_dflow_aggregator_v4`.
|
||||
//! Reserved executor for `router_dflow_aggregator_v4`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_dflow_aggregator_v4";
|
||||
/// Reserved executor for the `router_dflow_aggregator_v4` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterDflowAggregatorV4Executor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterDflowAggregatorV4Executor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_dflow_aggregator_v4";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_DFLOW_AGGREGATOR_V4_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_dflow_aggregator_v4"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_dflow_aggregator_v4".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/jupiter_aggregator_v4.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_jupiter_aggregator_v4`.
|
||||
//! Reserved executor for `router_jupiter_aggregator_v4`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_jupiter_aggregator_v4";
|
||||
/// Reserved executor for the `router_jupiter_aggregator_v4` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterJupiterAggregatorV4Executor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterJupiterAggregatorV4Executor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_jupiter_aggregator_v4";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_JUPITER_AGGREGATOR_V4_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_jupiter_aggregator_v4"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_jupiter_aggregator_v4".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/jupiter_aggregator_v6.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_jupiter_aggregator_v6`.
|
||||
//! Reserved executor for `router_jupiter_aggregator_v6`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_jupiter_aggregator_v6";
|
||||
/// Reserved executor for the `router_jupiter_aggregator_v6` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterJupiterAggregatorV6Executor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterJupiterAggregatorV6Executor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_jupiter_aggregator_v6";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_JUPITER_AGGREGATOR_V6_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_jupiter_aggregator_v6"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_jupiter_aggregator_v6".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/jupiter_dca.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_jupiter_dca`.
|
||||
//! Reserved executor for `router_jupiter_dca`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_jupiter_dca";
|
||||
/// Reserved executor for the `router_jupiter_dca` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterJupiterDcaExecutor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterJupiterDcaExecutor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_jupiter_dca";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_JUPITER_DCA_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_jupiter_dca"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_jupiter_dca".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/okx_labs_v1.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_okx_labs_v1`.
|
||||
//! Reserved executor for `router_okx_labs_v1`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_okx_labs_v1";
|
||||
/// Reserved executor for the `router_okx_labs_v1` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterOkxLabsV1Executor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterOkxLabsV1Executor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_okx_labs_v1";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_OKX_LABS_V1_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_okx_labs_v1"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_okx_labs_v1".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,49 @@
|
||||
// file: kb-lib/src/executor/router/okx_labs_v2.rs
|
||||
// version: 1
|
||||
// version: 2
|
||||
|
||||
//! Migration boundary for legacy crate `kb_executor_router_okx_labs_v2`.
|
||||
//! Reserved executor for `router_okx_labs_v2`.
|
||||
|
||||
/// Legacy crate name retained for migration and compatibility tracking.
|
||||
const LEGACY_CRATE: &str = "kb_executor_router_okx_labs_v2";
|
||||
/// Reserved executor for the `router_okx_labs_v2` program surface.
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct ExRouterOkxLabsV2Executor;
|
||||
|
||||
/// Current porting status.
|
||||
const MIGRATION_STATUS: &str = "source-preserved-pending-port";
|
||||
impl crate::ExApiInstructionExecutor for crate::ExRouterOkxLabsV2Executor {
|
||||
fn executor_name(&self) -> &'static str {
|
||||
return "kb_executor_router_okx_labs_v2";
|
||||
}
|
||||
|
||||
fn executor_version(&self) -> &'static str {
|
||||
return env!("CARGO_PKG_VERSION");
|
||||
}
|
||||
|
||||
fn program_ids(&self) -> &'static [&'static str] {
|
||||
return &[kb_program_ids::ROUTER_OKX_LABS_V2_PROGRAM_ID];
|
||||
}
|
||||
|
||||
fn supports_request(
|
||||
&self,
|
||||
request: &crate::ExApiExecutionRequest,
|
||||
) -> crate::ExApiExecutionSupport {
|
||||
if crate::ExApiInstructionExecutor::handles_program_id(self, &request.program_id) {
|
||||
return crate::ExApiExecutionSupport::Maybe;
|
||||
}
|
||||
return crate::ExApiExecutionSupport::No;
|
||||
}
|
||||
|
||||
fn build_plan(
|
||||
&self,
|
||||
_request: &crate::ExApiExecutionRequest,
|
||||
) -> kb_core::Result<crate::ExApiExecutionPlan> {
|
||||
let payload_json = match crate::executor_api_serialize_payload_json(
|
||||
&serde_json::json!({"status":"reserved_executor","surface":"router_okx_labs_v2"}),
|
||||
) {
|
||||
std::result::Result::Ok(serialized) => serialized,
|
||||
std::result::Result::Err(error) => return std::result::Result::Err(error),
|
||||
};
|
||||
return std::result::Result::Ok(crate::ExApiExecutionPlan {
|
||||
executor_name: "kb_executor_router_okx_labs_v2".to_string(),
|
||||
instruction_count: 0,
|
||||
payload_json,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user