Package org.osgi.framework

Examples of org.osgi.framework.Bundle.stop()


                    put( "v", l );
                }
            } );
            assertOrder( value, getConfigurationAdmin().getConfiguration( pid ).getProperties().get( "v" ) );

            cmBundle.stop();
            cmBundle.start();

            assertOrder( value, getConfigurationAdmin().getConfiguration( pid ).getProperties().get( "v" ) );
            getConfigurationAdmin().getConfiguration( pid, null ).delete();
        }
View Full Code Here


    Assert.assertNotNull("Instance of Obrman-Test-S3Impl is null", instance);
    Bundle bundle = implementation.getApformComponent().getBundle();

    try {
      bundle.stop();
    } catch (Exception e) {
      e.printStackTrace();
      fail(e.getMessage());
    }
View Full Code Here

        assertTrue(initLatch.await(5, TimeUnit.SECONDS));

        assertResponseCode(SC_OK, createURL("/test"));

        bundle.stop();

        assertTrue(destroyLatch.await(5, TimeUnit.SECONDS));

        try
        {
View Full Code Here

                else if ( "stop".equals( action ) )
                {
                    // stop bundle
                    try
                    {
                        bundle.stop();
                    }
                    catch ( BundleException be )
                    {
                        bundleException = be;
                        log( "Cannot stop", be );
View Full Code Here

    {
        Bundle bundle = getHttpJettyBundle();
        // Restart the HTTP-service to clean all registrations...
        if (bundle.getState() == Bundle.ACTIVE)
        {
            bundle.stop();
            bundle.start();
        }
    }

    /**
 
View Full Code Here

                        {
                            systemBundle.update();
                        }
                        else
                        {
                            systemBundle.stop();
                        }
                    }
                    catch ( BundleException be )
                    {
                        log( "Problem stopping or restarting the Framework", be );
View Full Code Here

        Group testGroup = (Group) userAdmin.createRole(groupName, Role.GROUP);
        testGroup.addMember(testUser);

        // Stop the file store...
        fileStoreBundle.stop();

        // retrieve the useradmin again...
        userAdmin = awaitService(UserAdmin.class.getName());

        // Verify the user + group are gone (no store available)...
View Full Code Here

        Group testGroup = (Group) userAdmin.createRole(groupName, Role.GROUP);
        testGroup.addMember(testUser);

        // Stop the file store...
        fileStoreBundle.stop();

        Bundle userAdminBundle = findBundle(ORG_APACHE_FELIX_USERADMIN);
        assertNotNull(userAdminBundle);
        userAdminBundle.stop();
View Full Code Here

        // Stop the file store...
        fileStoreBundle.stop();

        Bundle userAdminBundle = findBundle(ORG_APACHE_FELIX_USERADMIN);
        assertNotNull(userAdminBundle);
        userAdminBundle.stop();

        // Obtain user admin service again; shouldn't be available...
        userAdmin = getService(UserAdmin.class.getName());
        assertNull(userAdmin);
View Full Code Here

        group.addMember(user);
        group.addRequiredMember(ua.getRole(Role.USER_ANYONE));

        // Stop the file store; should persist the two roles...
        fileStoreBundle.stop();

        Thread.sleep(100); // Wait a little until the bundle is really stopped...

        // Retrieve the roles again; should both yield null due to the store not being available...
        user = (User) ua.getRole("user1");
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.