Examples of loadContribution()


Examples of org.apache.tuscany.sca.deployment.DefaultDeployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("../../../samples/learning-more/binding-sca/calculator-contribution/target/sample-binding-sca-calculator-contribution.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.DefaultDeployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("src/test/resources/sample-binding-sca-calculator-contribution.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.DefaultDeployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("../../samples/binding-sca/contribution-calculator/target/sample-contribution-binding-sca-calculator.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

        TuscanyRuntime tuscanyRuntime = TuscanyRuntime.newInstance();
        Node node = tuscanyRuntime.createNode("myDomain");
       
        Deployer deployer = tuscanyRuntime.getDeployer();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(URI.create("foo"), new File("src/test/resources/sample-helloworld-nodeployable.jar").toURI().toURL(), monitor);
        monitor.analyzeProblems();
       
        node.installContribution(contribution, null, true);
        List<String> ics = node.getInstalledContributionURIs();
        Assert.assertEquals(1, ics.size());
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("../../../samples/learning-more/binding-sca/calculator-contribution/target/sample-binding-sca-calculator-contribution.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

        NodeFactory nodeFactory = NodeFactory.newInstance();
        Node node = nodeFactory.createNode("myDomain");
       
        Deployer deployer = nodeFactory.getDeployer();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(URI.create("foo"), new File("src/test/resources/sample-helloworld-nodeployable.jar").toURI().toURL(), monitor);
        monitor.analyzeProblems();
       
        node.installContribution(contribution, null, true);
        List<String> ics = node.getInstalledContributions();
        Assert.assertEquals(1, ics.size());
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("src/test/resources/sample-binding-sca-calculator-contribution.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

        ExtensionPointRegistry registry = new DefaultExtensionPointRegistry();
        Deployer deployer = registry.getExtensionPoint(UtilityExtensionPoint.class).getUtility(Deployer.class);
        URL r = getClass().getResource("/test.composite");
        r = new URL(r, "../");
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(URI.create("c1"), r, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
        int i = 0;
        for (Problem p : monitor.getProblems()) {
            System.err.println(i + ": " + p);
            i++;
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

        TuscanyRuntime tuscanyRuntime = TuscanyRuntime.newInstance();
        Node node = tuscanyRuntime.createNode("myDomain");
       
        Deployer deployer = tuscanyRuntime.getDeployer();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(URI.create("foo"), new File("src/test/resources/sample-helloworld-nodeployable.jar").toURI().toURL(), monitor);
        monitor.analyzeProblems();
       
        node.installContribution(contribution, null);
        List<String> ics = node.getInstalledContributionURIs();
        Assert.assertEquals(1, ics.size());
View Full Code Here

Examples of org.apache.tuscany.sca.deployment.Deployer.loadContribution()

    public void testRead() throws Exception {
        Deployer deployer = new DefaultDeployer();
        File file = new File("../../samples/binding-sca/contribution-calculator/target/sample-contribution-binding-sca-calculator.jar");
        URL url = file.toURI().toURL();
        Monitor monitor = deployer.createMonitor();
        Contribution contribution = deployer.loadContribution(url.toURI(), url, monitor);
        deployer.build(Arrays.asList(contribution), Arrays.asList(contribution), null, monitor);
       
        // Ferkle around in the contribution verifying it looks as expected
        Assert.assertNotNull(contribution);
        List<Composite> deployables = contribution.getDeployables();
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.