You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-07-31 09:24:31 +03:00
Use re-exported wasmtime to avoid dependencies conflicts
This commit is contained in:
@ -20,7 +20,6 @@ schemars = { workspace = true, optional = true }
|
||||
thiserror.workspace = true
|
||||
tokio.workspace = true
|
||||
tracing.workspace = true
|
||||
wasmtime = { version = "20.0.2", default-features = false, features = ["async", "cranelift", "parallel-compilation"] }
|
||||
|
||||
mas-data-model.workspace = true
|
||||
oauth2-types.workspace = true
|
||||
|
@ -16,10 +16,12 @@ pub mod model;
|
||||
|
||||
use mas_data_model::{AuthorizationGrant, Client, DeviceCodeGrant, User};
|
||||
use oauth2_types::{registration::VerifiedClientMetadata, scope::Scope};
|
||||
use opa_wasm::Runtime;
|
||||
use opa_wasm::{
|
||||
wasmtime::{Config, Engine, Module, OptLevel, Store},
|
||||
Runtime,
|
||||
};
|
||||
use thiserror::Error;
|
||||
use tokio::io::{AsyncRead, AsyncReadExt};
|
||||
use wasmtime::{Config, Engine, Module, Store};
|
||||
|
||||
use self::model::{
|
||||
AuthorizationGrantInput, ClientRegistrationInput, EmailInput, PasswordInput, RegisterInput,
|
||||
@ -95,7 +97,7 @@ impl PolicyFactory {
|
||||
) -> Result<Self, LoadError> {
|
||||
let mut config = Config::default();
|
||||
config.async_support(true);
|
||||
config.cranelift_opt_level(wasmtime::OptLevel::SpeedAndSize);
|
||||
config.cranelift_opt_level(OptLevel::SpeedAndSize);
|
||||
|
||||
let engine = Engine::new(&config).map_err(LoadError::Engine)?;
|
||||
|
||||
|
Reference in New Issue
Block a user