//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void testFallbackSerializerDoesNotOverrideRegularSerializer() public virtual void testFallbackSerializerDoesNotOverrideRegularSerializer() { // given // that the process engine is configured with a serializer for a certain format // and a fallback serializer factory for the same format ProcessEngineConfigurationImpl engineConfiguration = (new StandaloneInMemProcessEngineConfiguration()).setJdbcUrl("jdbc:h2:mem:camunda-forceclose").setProcessEngineName("engine-forceclose"); engineConfiguration.CustomPreVariableSerializers = Arrays.asList <TypedValueSerializer>(new ExampleConstantSerializer()); engineConfiguration.FallbackSerializerFactory = new ExampleSerializerFactory(); processEngine = engineConfiguration.buildProcessEngine(); deployOneTaskProcess(processEngine); // when setting a variable that no regular serializer can handle ObjectValue objectValue = Variables.objectValue("foo").serializationDataFormat(ExampleSerializer.FORMAT).create(); ProcessInstance pi = processEngine.RuntimeService.startProcessInstanceByKey("oneTaskProcess", Variables.createVariables().putValueTyped("var", objectValue)); ObjectValue fetchedValue = processEngine.RuntimeService.getVariableTyped(pi.Id, "var", true); // then the fallback serializer is used Assert.assertNotNull(fetchedValue); Assert.assertEquals(ExampleSerializer.FORMAT, fetchedValue.SerializationDataFormat); Assert.assertEquals(ExampleConstantSerializer.DESERIALIZED_VALUE, fetchedValue.Value); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @After public void resetBatchJobsPerSeed() public virtual void resetBatchJobsPerSeed() { ProcessEngineConfigurationImpl processEngineConfiguration = engineRule.ProcessEngineConfiguration; processEngineConfiguration.BatchJobsPerSeed = defaultBatchJobsPerSeed; processEngineConfiguration.BatchJobPriority = defaultBatchJobPriority; }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void init() public virtual void init() { processEngineConfiguration = engineRule.ProcessEngineConfiguration; identityService = engineRule.IdentityService; authorizationService = engineRule.AuthorizationService; managementService = engineRule.ManagementService; }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void testBuiltinFunctionMapperRegistration() public virtual void testBuiltinFunctionMapperRegistration() { // given a process engine configuration with a custom function mapper ProcessEngineConfigurationImpl config = (ProcessEngineConfigurationImpl)ProcessEngineConfiguration.createStandaloneInMemProcessEngineConfiguration().setJdbcUrl("jdbc:h2:mem:camunda" + this.GetType().Name); CustomExpressionManager customExpressionManager = new CustomExpressionManager(); Assert.assertTrue(customExpressionManager.FunctionMappers.Count == 0); config.ExpressionManager = customExpressionManager; // when the engine is initialized engine = config.buildProcessEngine(); // then two default function mappers should be registered Assert.assertSame(customExpressionManager, config.ExpressionManager); Assert.assertEquals(2, customExpressionManager.FunctionMappers.Count); bool commandContextMapperFound = false; bool dateTimeMapperFound = false; foreach (FunctionMapper functionMapper in customExpressionManager.FunctionMappers) { if (functionMapper is CommandContextFunctionMapper) { commandContextMapperFound = true; } if (functionMapper is DateTimeFunctionMapper) { dateTimeMapperFound = true; } } Assert.assertTrue(commandContextMapperFound && dateTimeMapperFound); }
public override ProcessEngineConfiguration configureEngine(ProcessEngineConfigurationImpl configuration) { tenantIdProvider = new StaticTenantIdTestProvider(TENANT_ONE); configuration.TenantIdProvider = tenantIdProvider; return(configuration); }
public static void Main(string[] args) { ProcessEngineConfigurationImpl processEngineConfiguration = (ProcessEngineConfigurationImpl)ProcessEngineConfiguration.createProcessEngineConfigurationFromResource("camunda.cfg.xml"); ProcessEngine processEngine = processEngineConfiguration.buildProcessEngine(); // register test scenarios ScenarioRunner runner = new ScenarioRunner(processEngine, ENGINE_VERSION); // cmmn sentries runner.setupScenarios(typeof(SentryScenario)); // compensation runner.setupScenarios(typeof(SingleActivityCompensationScenario)); runner.setupScenarios(typeof(NestedCompensationScenario)); runner.setupScenarios(typeof(SingleActivityConcurrentCompensationScenario)); runner.setupScenarios(typeof(ParallelMultiInstanceCompensationScenario)); runner.setupScenarios(typeof(SequentialMultiInstanceCompensationScenario)); runner.setupScenarios(typeof(NestedMultiInstanceCompensationScenario)); runner.setupScenarios(typeof(InterruptingEventSubProcessCompensationScenario)); runner.setupScenarios(typeof(NonInterruptingEventSubProcessCompensationScenario)); runner.setupScenarios(typeof(InterruptingEventSubProcessNestedCompensationScenario)); // job runner.setupScenarios(typeof(JobMigrationScenario)); // boundary events runner.setupScenarios(typeof(NonInterruptingBoundaryEventScenario)); processEngine.close(); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: //ORIGINAL LINE: public void testPerformDatabaseSchemaOperationCreateTwice() throws Exception public virtual void testPerformDatabaseSchemaOperationCreateTwice() { // both process engines will be using this datasource. PooledDataSource pooledDataSource = new PooledDataSource(ReflectUtil.ClassLoader, "org.h2.Driver", "jdbc:h2:mem:DatabaseTablePrefixTest;DB_CLOSE_DELAY=1000", "sa", ""); Connection connection = pooledDataSource.Connection; connection.createStatement().execute("drop schema if exists " + SCHEMA_NAME); connection.createStatement().execute("create schema " + SCHEMA_NAME); connection.close(); ProcessEngineConfigurationImpl config1 = createCustomProcessEngineConfiguration().setProcessEngineName("DatabaseTablePrefixTest-engine1").setDataSource(pooledDataSource).setDatabaseSchemaUpdate("NO_CHECK"); config1.DatabaseTablePrefix = SCHEMA_NAME + "."; config1.DatabaseSchema = SCHEMA_NAME; config1.DbMetricsReporterActivate = false; ProcessEngine engine1 = config1.buildProcessEngine(); // create the tables for the first time connection = pooledDataSource.Connection; connection.createStatement().execute("set schema " + SCHEMA_NAME); engine1.ManagementService.databaseSchemaUpgrade(connection, "", SCHEMA_NAME); connection.close(); // create the tables for the second time; here we shouldn't crash since the // session should tell us that the tables are already present and // databaseSchemaUpdate is set to noop connection = pooledDataSource.Connection; connection.createStatement().execute("set schema " + SCHEMA_NAME); engine1.ManagementService.databaseSchemaUpgrade(connection, "", SCHEMA_NAME); engine1.close(); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void init() public virtual void init() { identityService = engineRule.IdentityService; processEngineConfiguration = engineRule.ProcessEngineConfiguration; processEngineConfiguration.PasswordPolicy = new DefaultPasswordPolicyImpl(); processEngineConfiguration.EnablePasswordPolicy = true; }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void init() public virtual void init() { processEngineConfiguration = engineRule.ProcessEngineConfiguration; identityService = engineRule.IdentityService; identityService.setAuthentication("user", null, null); }
protected internal virtual void compileScript(ScriptEngine engine) { ProcessEngineConfigurationImpl processEngineConfiguration = Context.ProcessEngineConfiguration; if (processEngineConfiguration.EnableScriptEngineCaching && processEngineConfiguration.EnableScriptCompilation) { if (CompiledScript == null && shouldBeCompiled) { lock (this) { if (CompiledScript == null && shouldBeCompiled) { // try to compile script compiledScript = compile(engine, language, scriptSource); // either the script was successfully compiled or it can't be // compiled but we won't try it again shouldBeCompiled = false; } } } } else { // if script compilation is disabled abort shouldBeCompiled = false; } }
/// <summary> /// Loads the given script engine by language name. Will throw an exception if no script engine can be loaded for the given language name. /// </summary> /// <param name="language"> the name of the script language to lookup an implementation for </param> /// <returns> the script engine </returns> /// <exception cref="ProcessEngineException"> if no such engine can be found. </exception> public virtual ScriptEngine getScriptEngineForLanguage(string language) { if (!string.ReferenceEquals(language, null)) { language = language.ToLower(); } ProcessApplicationReference pa = Context.CurrentProcessApplication; ProcessEngineConfigurationImpl config = Context.ProcessEngineConfiguration; ScriptEngine engine = null; if (config.EnableFetchScriptEngineFromProcessApplication) { if (pa != null) { engine = getPaScriptEngine(language, pa); } } if (engine == null) { engine = getGlobalScriptEngine(language); } return(engine); }
public static int?getTransactionIsolationLevel(ProcessEngineConfigurationImpl processEngineConfiguration) { //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final System.Nullable<int>[] transactionIsolation = new System.Nullable<int>[1]; int?[] transactionIsolation = new int?[1]; processEngineConfiguration.CommandExecutorTxRequired.execute(new CommandAnonymousInnerClass(transactionIsolation)); return(transactionIsolation[0]); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Override @Before public void setup() public override void setup() { base.setup(); ProcessEngineConfigurationImpl engineConfiguration = ((ProcessEngineImpl)engine).ProcessEngineConfiguration; jobExecutor = engineConfiguration.JobExecutor; jobExecutor.start(); }
// queries ///////////////////////////////// protected internal virtual CaseSentryPartQueryImpl createCaseSentryPartQuery() { ProcessEngine processEngine = rule.ProcessEngine; ProcessEngineConfigurationImpl processEngineConfiguration = (ProcessEngineConfigurationImpl)processEngine.ProcessEngineConfiguration; CommandExecutor commandExecutor = processEngineConfiguration.CommandExecutorTxRequiresNew; return(new CaseSentryPartQueryImpl(commandExecutor)); }
public override ProcessEngineConfiguration configureEngine(ProcessEngineConfigurationImpl configuration) { configuration.JdbcUrl = "jdbc:h2:mem:DeploymentTest-HistoryLevelNone;DB_CLOSE_DELAY=1000"; configuration.DatabaseSchemaUpdate = ProcessEngineConfiguration.DB_SCHEMA_UPDATE_CREATE_DROP; configuration.HistoryLevel = org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_NONE; configuration.DbHistoryUsed = false; return(configuration); }
public override ProcessEngineConfiguration configureEngine(ProcessEngineConfigurationImpl configuration) { TenantIdProvider tenantIdProvider = new VariableBasedTenantIdProvider(); configuration.TenantIdProvider = tenantIdProvider; return(configuration); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void saveAndReduceBatchJobsPerSeed() public virtual void saveAndReduceBatchJobsPerSeed() { ProcessEngineConfigurationImpl configuration = engineRule.ProcessEngineConfiguration; defaultBatchJobsPerSeed = configuration.BatchJobsPerSeed; // reduce number of batch jobs per seed to not have to create a lot of instances configuration.BatchJobsPerSeed = 1; }
public virtual void notify(DmnDecisionEvaluationEvent evaluationEvent) { ProcessEngineConfigurationImpl processEngineConfiguration = Context.ProcessEngineConfiguration; if (processEngineConfiguration != null && processEngineConfiguration.MetricsEnabled) { processEngineConfiguration.MetricsRegistry.markOccurrence(Metrics.EXECUTED_DECISION_ELEMENTS, evaluationEvent.ExecutedDecisionElements); } }
public virtual void submitFormVariables(VariableMap properties, VariableScope variableScope) { ProcessEngineConfigurationImpl processEngineConfiguration = Context.ProcessEngineConfiguration; IdentityService identityService = processEngineConfiguration.IdentityService; RuntimeService runtimeService = processEngineConfiguration.RuntimeService; logAuthentication(identityService); logInstancesCount(runtimeService); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: //ORIGINAL LINE: protected void handleInvocationInContext(final DelegateInvocation invocation) throws Exception //JAVA TO C# CONVERTER WARNING: 'final' parameters are not available in .NET: protected internal virtual void handleInvocationInContext(DelegateInvocation invocation) { CommandContext commandContext = Context.CommandContext; bool wasAuthorizationCheckEnabled = commandContext.AuthorizationCheckEnabled; bool wasUserOperationLogEnabled = commandContext.UserOperationLogEnabled; BaseDelegateExecution contextExecution = invocation.ContextExecution; ProcessEngineConfigurationImpl configuration = Context.ProcessEngineConfiguration; bool popExecutionContext = false; try { if (!configuration.AuthorizationEnabledForCustomCode) { // the custom code should be executed without authorization commandContext.disableAuthorizationCheck(); } try { commandContext.disableUserOperationLog(); try { if (contextExecution != null && !isCurrentContextExecution(contextExecution)) { popExecutionContext = setExecutionContext(contextExecution); } invocation.proceed(); } finally { if (popExecutionContext) { Context.removeExecutionContext(); } } } finally { if (wasUserOperationLogEnabled) { commandContext.enableUserOperationLog(); } } } finally { if (wasAuthorizationCheckEnabled) { commandContext.enableAuthorizationCheck(); } } }
public virtual void testPluginRegistersJsonSerializerIfPresentInClasspath() { DataFormats.loadDataFormats(null); ProcessEngineConfigurationImpl mockConfig = Mockito.mock(typeof(ProcessEngineConfigurationImpl)); Mockito.when(mockConfig.VariableSerializers).thenReturn(processEngineConfiguration.VariableSerializers); (new SpinProcessEnginePlugin()).registerSerializers(mockConfig); assertTrue(processEngineConfiguration.VariableSerializers.getSerializerByName(org.camunda.spin.plugin.variable.type.JsonValueType_Fields.TYPE_NAME) is JsonValueSerializer); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void shouldPerformDatabaseSchemaOperationCreate() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: public virtual void shouldPerformDatabaseSchemaOperationCreate() { // both process engines will be using this datasource. PooledDataSource pooledDataSource = new PooledDataSource(ReflectUtil.ClassLoader, "org.h2.Driver", "jdbc:h2:mem:DatabaseTablePrefixTest;DB_CLOSE_DELAY=1000", "sa", ""); // create two schemas is the database Connection connection = pooledDataSource.Connection; connection.createStatement().execute("drop schema if exists SCHEMA1"); connection.createStatement().execute("drop schema if exists SCHEMA2"); connection.createStatement().execute("create schema SCHEMA1"); connection.createStatement().execute("create schema SCHEMA2"); connection.close(); // configure & build two different process engines, each having a separate table prefix ProcessEngineConfigurationImpl config1 = createCustomProcessEngineConfiguration().setProcessEngineName("DatabaseTablePrefixTest-engine1").setDataSource(pooledDataSource).setDbMetricsReporterActivate(false).setDatabaseSchemaUpdate("NO_CHECK"); // disable auto create/drop schema config1.DatabaseTablePrefix = "SCHEMA1."; config1.UseSharedSqlSessionFactory = true; ProcessEngine engine1 = config1.buildProcessEngine(); ProcessEngineConfigurationImpl config2 = createCustomProcessEngineConfiguration().setProcessEngineName("DatabaseTablePrefixTest-engine2").setDataSource(pooledDataSource).setDbMetricsReporterActivate(false).setDatabaseSchemaUpdate("NO_CHECK"); // disable auto create/drop schema config2.DatabaseTablePrefix = "SCHEMA2."; config2.UseSharedSqlSessionFactory = true; ProcessEngine engine2 = config2.buildProcessEngine(); // create the tables in SCHEMA1 connection = pooledDataSource.Connection; connection.createStatement().execute("set schema SCHEMA1"); engine1.ManagementService.databaseSchemaUpgrade(connection, "", "SCHEMA1"); connection.close(); // create the tables in SCHEMA2 connection = pooledDataSource.Connection; connection.createStatement().execute("set schema SCHEMA2"); engine2.ManagementService.databaseSchemaUpgrade(connection, "", "SCHEMA2"); connection.close(); // if I deploy a process to one engine, it is not visible to the other // engine: try { engine1.RepositoryService.createDeployment().addClasspathResource("org/camunda/bpm/engine/test/api/cfg/oneJobProcess.bpmn20.xml").deploy(); assertEquals(1, engine1.RepositoryService.createDeploymentQuery().count()); assertEquals(0, engine2.RepositoryService.createDeploymentQuery().count()); } finally { engine1.close(); engine2.close(); ProcessEngineConfigurationImpl.cachedSqlSessionFactory = null; } }
protected internal override void checkAuthorization(CommandContext commandContext) { ProcessEngineConfigurationImpl processEngineConfiguration = Context.ProcessEngineConfiguration; DeploymentCache deploymentCache = processEngineConfiguration.DeploymentCache; ProcessDefinitionEntity processDefinition = deploymentCache.findDeployedProcessDefinitionById(processDefinitionId); foreach (CommandChecker checker in commandContext.ProcessEngineConfiguration.CommandCheckers) { checker.checkReadProcessDefinition(processDefinition); } }
public virtual bool validate(object submittedValue, FormFieldValidatorContext validatorContext) { ProcessEngineConfigurationImpl processEngineConfiguration = Context.ProcessEngineConfiguration; IdentityService identityService = processEngineConfiguration.IdentityService; RuntimeService runtimeService = processEngineConfiguration.RuntimeService; logAuthentication(identityService); logInstancesCount(runtimeService); return(true); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void shouldInitHistoryLevelByString() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: public virtual void shouldInitHistoryLevelByString() { ProcessEngineConfigurationImpl config = createConfig(); config.History = org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_FULL.Name; ProcessEngineConfigurationImpl processEngineConfiguration = buildProcessEngine(config); assertThat(processEngineConfiguration.HistoryLevels.Count, @is(4)); assertThat(processEngineConfiguration.HistoryLevel, @is(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_FULL)); assertThat(processEngineConfiguration.History, @is(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_FULL.Name)); }
public override void postInit(ProcessEngineConfigurationImpl processEngineConfiguration) { authorizationEnabled = processEngineConfiguration.AuthorizationEnabled; if (!string.ReferenceEquals(administratorGroupName, null) && administratorGroupName.Length > 0) { processEngineConfiguration.AdminGroups.Add(administratorGroupName); } if (!string.ReferenceEquals(administratorUserName, null) && administratorUserName.Length > 0) { processEngineConfiguration.AdminUsers.Add(administratorUserName); } }
public static void Main(string[] args) { ProcessEngineConfigurationImpl processEngineConfiguration = (ProcessEngineConfigurationImpl)ProcessEngineConfiguration.createProcessEngineConfigurationFromResource("camunda.cfg.xml"); ProcessEngine processEngine = processEngineConfiguration.buildProcessEngine(); // register test scenarios ScenarioRunner runner = new ScenarioRunner(processEngine, ENGINE_VERSION); // event subprocesses runner.setupScenarios(typeof(InterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(NonInterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(NestedNonInterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(ParallelNestedNonInterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(NestedParallelNonInterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(NestedNonInterruptingEventSubprocessNestedSubprocessScenario)); runner.setupScenarios(typeof(NestedInterruptingErrorEventSubprocessScenario)); runner.setupScenarios(typeof(TwoLevelNestedNonInterruptingEventSubprocessScenario)); runner.setupScenarios(typeof(NestedInterruptingEventSubprocessParallelScenario)); // multi instance runner.setupScenarios(typeof(SequentialMultiInstanceSubprocessScenario)); runner.setupScenarios(typeof(NestedSequentialMultiInstanceSubprocessScenario)); runner.setupScenarios(typeof(MultiInstanceReceiveTaskScenario)); runner.setupScenarios(typeof(ParallelMultiInstanceSubprocessScenario)); // async runner.setupScenarios(typeof(AsyncParallelMultiInstanceScenario)); runner.setupScenarios(typeof(AsyncSequentialMultiInstanceScenario)); // boundary event runner.setupScenarios(typeof(NonInterruptingBoundaryEventScenario)); runner.setupScenarios(typeof(NestedNonInterruptingBoundaryEventOnInnerSubprocessScenario)); runner.setupScenarios(typeof(NestedNonInterruptingBoundaryEventOnOuterSubprocessScenario)); // compensation runner.setupScenarios(typeof(SingleActivityCompensationScenario)); runner.setupScenarios(typeof(SubprocessCompensationScenario)); runner.setupScenarios(typeof(TransactionCancelCompensationScenario)); runner.setupScenarios(typeof(InterruptingEventSubprocessCompensationScenario)); runner.setupScenarios(typeof(SubprocessParallelThrowCompensationScenario)); runner.setupScenarios(typeof(SubprocessParallelCreateCompensationScenario)); // plain tasks runner.setupScenarios(typeof(OneTaskScenario)); runner.setupScenarios(typeof(OneScopeTaskScenario)); runner.setupScenarios(typeof(ParallelTasksScenario)); runner.setupScenarios(typeof(ParallelScopeTasksScenario)); // event-based gateway runner.setupScenarios(typeof(EventBasedGatewayScenario)); processEngine.close(); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void readLevelFullfromDB() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: public virtual void readLevelFullfromDB() { //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl config = config("true", org.camunda.bpm.engine.ProcessEngineConfiguration.HISTORY_FULL); ProcessEngineConfigurationImpl config = config("true", ProcessEngineConfiguration.HISTORY_FULL); // init the db with level=full processEngineImpl = (ProcessEngineImpl)config.buildProcessEngine(); HistoryLevel historyLevel = config.CommandExecutorSchemaOperations.execute(new DetermineHistoryLevelCmd(config.HistoryLevels)); assertThat(historyLevel, CoreMatchers.equalTo(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_FULL)); }
public static void Main(string[] args) { ProcessEngineConfigurationImpl processEngineConfiguration = (ProcessEngineConfigurationImpl)ProcessEngineConfiguration.createProcessEngineConfigurationFromResource("camunda.cfg.xml"); ProcessEngine processEngine = processEngineConfiguration.buildProcessEngine(); // register test scenarios ScenarioRunner runner = new ScenarioRunner(processEngine, ENGINE_VERSION); // compensation runner.setupScenarios(typeof(DeployProcessWithoutIsExecutableAttributeScenario)); processEngine.close(); }
public override void postInit(ProcessEngineConfigurationImpl processEngineConfiguration) { SqlSessionFactory sqlSessionFactory = processEngineConfiguration.SqlSessionFactory; // wrap the SqlSessionFactory using a statement logger StatementLogSqlSessionFactory wrappedSessionFactory = new StatementLogSqlSessionFactory(sqlSessionFactory); processEngineConfiguration.SqlSessionFactory = wrappedSessionFactory; // replace the sqlSessionFacorty used by the DbSqlSessionFactory as well DbSqlSessionFactory dbSqlSessionFactory = processEngineConfiguration.DbSqlSessionFactory; dbSqlSessionFactory.SqlSessionFactory = wrappedSessionFactory; }