Examples of DeploymentType


Examples of org.apache.isis.core.runtime.system.DeploymentType

    private DeploymentTypeWicketAbstract determineDeploymentType(String deploymentTypeFromConfig) {
        final DeploymentTypeWicketAbstract prototype = new WicketServerPrototype();
        final DeploymentTypeWicketAbstract deployment = new WicketServer();
       
        if(deploymentTypeFromConfig != null) {
            final DeploymentType deploymentType = DeploymentType.lookup(deploymentTypeFromConfig);
            return !deploymentType.getDeploymentCategory().isProduction()
                    ? prototype
                    : deployment;
        } else {
            return usesDevelopmentConfig()
                    ? prototype
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        getRequestCycleListeners().add(new WebRequestCycleForIsis());



        getResourceSettings().setParentFolderPlaceholder("$up$");
        final DeploymentType deploymentType = determineDeploymentType();

        final IsisConfigurationBuilder isisConfigurationBuilder = createConfigBuilder(getServletContext());

        final IsisInjectModule isisModule = new IsisInjectModule(deploymentType, isisConfigurationBuilder);
        final Injector injector = Guice.createInjector(isisModule, newIsisWicketModule());
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

            primeConfigurationBuilder(isisConfigurationBuilder, servletContext);

            isisConfigurationBuilder.addDefaultConfigurationResources();

            final DeploymentType deploymentType = determineDeploymentType(isisConfigurationBuilder, servletContext);

            addConfigurationResourcesForWebApps(isisConfigurationBuilder);
            addConfigurationResourcesForDeploymentType(isisConfigurationBuilder, deploymentType);
            IsisWebAppBootstrapperUtil.addConfigurationResourcesForViewers(isisConfigurationBuilder, servletContext);
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        IsisSystemUsingInstallersWithinJunit system = null;
        AuthenticationSession session = null;
        try {
            // init the system; cf similar code in Isis and
            // IsisServletContextInitializer
            final DeploymentType deploymentType = DeploymentType.PROTOTYPE;

            // TODO: replace with regular IsisSystem and remove this subclass.
            system = new IsisSystemUsingInstallersWithinJunit(deploymentType, installerLookup, testClass);

            system.init();
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        return serviceInstantiator.createInstance(cls);
    }

    private void appendObjectFixtureService(final IsisConfiguration configuration, final String root, List<Object> serviceList) {
        if (configuration.getBoolean(root + EXPLORATION_OBJECTS)) {
            final DeploymentType deploymentType = DeploymentType.lookup(configuration.getString(SystemConstants.DEPLOYMENT_TYPE_KEY));
            if (deploymentType.isExploring()) {
                serviceList.add(new ObjectFixtureService());
            }
        }
    }
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        }
        return true;
    }

    private boolean validateOptions(final Options options, final BootPrinter printer) {
        final DeploymentType deploymentType = optionHandlerDeploymentType.getDeploymentType();

        for (final OptionValidator validator : validators) {
            final Optional<String> errorMessage = validator.validate(deploymentType);
            if (errorMessage.isPresent()) {
                printer.printErrorAndHelp(options, errorMessage.get());
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

    // TODO remove and use is desktop runner

    public final void bootstrap(final IsisBootstrapper bootstrapper) {

        final DeploymentType deploymentType = optionHandlerDeploymentType.getDeploymentType();

        this.globalInjector = createGuiceInjector(deploymentType, isisConfigurationBuilder, installerLookup, optionHandlers);

        bootstrapper.bootstrap(globalInjector);
        isisConfigurationBuilder.lockConfiguration();
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        assertThat(authenticator.getConfiguration(), is(mockConfiguration));
    }

    @Test
    public void getDeploymentTypeForExploration() throws Exception {
        final DeploymentType deploymentType = DeploymentType.EXPLORATION;
        mockery.checking(new Expectations() {
            {
                allowing(mockConfiguration).getString("isis.deploymentType");
                will(returnValue(deploymentType.name()));
            }
        });
        assertThat(authenticator.getDeploymentType(), is(deploymentType));
    }
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        assertThat(authenticator.getDeploymentType(), is(deploymentType));
    }

    @Test
    public void getDeploymentTypeForPrototype() throws Exception {
        final DeploymentType deploymentType = DeploymentType.PROTOTYPE;
        mockery.checking(new Expectations() {
            {
                allowing(mockConfiguration).getString("isis.deploymentType");
                will(returnValue(deploymentType.name()));
            }
        });
        assertThat(authenticator.getDeploymentType(), is(deploymentType));
    }
View Full Code Here

Examples of org.apache.isis.core.runtime.system.DeploymentType

        assertThat(authenticator.getDeploymentType(), is(deploymentType));
    }

    @Test
    public void getDeploymentTypeForServer() throws Exception {
        final DeploymentType deploymentType = DeploymentType.SERVER;
        mockery.checking(new Expectations() {
            {
                allowing(mockConfiguration).getString("isis.deploymentType");
                will(returnValue(deploymentType.name()));
            }
        });
        assertThat(authenticator.getDeploymentType(), is(deploymentType));
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.