How moqui/moqui-framework works
Moqui Framework is a runtime framework for executing application services and managing shared execution context, entities, screens, and integrations. A typical invocation enters through the service API, resolves and validates a service definition, then runs it with thread-scoped context and access to framework facilities. Entity querying and persistence, screen rendering, ETL, and remote calls are distinct capabilities rather than a single assumed pipeline. The graph follows documented interfaces and indexed source references; several subsystem links are omitted where sampled excerpts do not establish the runtime caller.
Main entry points: ServiceFacade.java Service facade · EntityFacade.java Entity facade · ExecutionContext.java Execution context API · ServiceCallImpl.java Service call
Components 21
Execution context
- Execution context API
framework/src/main/java/org/moqui/context/ExecutionContext.java - Execution context
framework/src/main/groovy/org/moqui/impl/context/ExecutionContextImpl.java - Context stack
framework/src/main/java/org/moqui/util/ContextStack.java - Artifact execution
framework/src/main/java/org/moqui/context/ArtifactExecutionInfo.java
Service runtime
- Service API
framework/src/main/java/org/moqui/service/ServiceCall.java - Service facade
framework/src/main/java/org/moqui/service/ServiceFacade.java - Service call
framework/src/main/groovy/org/moqui/impl/service/ServiceCallImpl.java - Synchronous dispatch
framework/src/main/groovy/org/moqui/impl/service/ServiceCallSyncImpl.java - Service definition
framework/src/main/groovy/org/moqui/impl/service/ServiceDefinition.java - Service runners
framework/src/main/groovy/org/moqui/impl/service/runner
Data and ETL
- Entity facade
framework/src/main/java/org/moqui/entity/EntityFacade.java - Entity queries
framework/src/main/groovy/org/moqui/impl/entity/EntityQueryBuilder.java - Entity values
framework/src/main/java/org/moqui/entity/EntityValue.java - Entity results
framework/src/main/java/org/moqui/entity/EntityList.java - Simple ETL
framework/src/main/java/org/moqui/etl/SimpleEtl.java
Screens and integrations
- Screen facade
framework/src/main/java/org/moqui/screen/ScreenFacade.java - Screen rendering
framework/src/main/groovy/org/moqui/impl/screen/ScreenWidgetRender.java - Resource access
framework/src/main/java/org/moqui/context/ResourceFacade.java - REST client
framework/src/main/java/org/moqui/util/RestClient.java
Other components
- Application caller
- Remote services
Connections 19
- Application caller → Service API: invokes
- Service API → Service facade: obtains caller
framework/src/main/java/org/moqui/service/ServiceFacade.java - Service facade → Service call: creates call
- Service call → Service definition: resolves
framework/src/main/groovy/org/moqui/impl/service/ServiceCallImpl.java - Service call → Synchronous dispatch: dispatches
framework/src/main/groovy/org/moqui/impl/service/ServiceCallSyncImpl.java - Synchronous dispatch → Service definition: uses definition
framework/src/main/groovy/org/moqui/impl/service/ServiceCallSyncImpl.java - Synchronous dispatch → Execution context: uses context
framework/src/main/groovy/org/moqui/impl/service/ServiceCallSyncImpl.java - Service definition → Service runners: selects runner
framework/src/main/groovy/org/moqui/impl/service/runner/ScriptServiceRunner.java - Execution context API → Execution context: implemented by
framework/src/main/groovy/org/moqui/impl/context/ExecutionContextImpl.java - Execution context → Context stack: owns stack
framework/src/main/groovy/org/moqui/impl/context/ExecutionContextImpl.java - Execution context API → Entity facade: exposes
framework/src/main/java/org/moqui/context/ExecutionContext.java - Execution context API → Screen facade: exposes
framework/src/main/java/org/moqui/context/ExecutionContext.java - Entity queries → Entity facade: builds queries for
- Entity facade → Entity values: returns values
framework/src/main/java/org/moqui/entity/EntityFacade.java - Entity facade → Entity results: returns results
- Screen facade → Screen rendering: renders screens
- Service facade → REST client: provides client
framework/src/main/java/org/moqui/service/ServiceFacade.java - Service facade → Remote services: calls JSON RPC
framework/src/main/java/org/moqui/service/ServiceFacade.java - REST client → Remote services: sends requests
framework/src/main/java/org/moqui/util/RestClient.java