// Get factory extension point
ModelFactoryExtensionPoint factories = registry.getExtensionPoint(ModelFactoryExtensionPoint.class);
// Create context factory extension point
ContextFactoryExtensionPoint contextFactories = new DefaultContextFactoryExtensionPoint();
registry.addExtensionPoint(contextFactories);
// Create Message factory
MessageFactory messageFactory = new MessageFactoryImpl();
factories.addFactory(messageFactory);