Examples of persistence()


Examples of net.sf.ehcache.config.CacheConfiguration.persistence()

        }
        else
        {
            persistenceConfig.strategy( strategy );
        }
        cacheConfig.persistence( persistenceConfig );

        return cacheConfig;
    }

}
View Full Code Here

Examples of org.apache.isis.core.metamodel.facets.actions.command.CommandFacet.persistence()

                // copy over the command execution 'context' (if available)
                final CommandFacet commandFacet = getFacetHolder().getFacet(CommandFacet.class);
                if(commandFacet != null && !commandFacet.isDisabled()) {
                    command.setExecuteIn(commandFacet.executeIn());
                    command.setPersistence(commandFacet.persistence());
                } else {
                    // if no facet, assume do want to execute right now, but only persist (eventually) if hinted.
                    command.setExecuteIn(ExecuteIn.FOREGROUND);
                    command.setPersistence(Persistence.IF_HINTED);
                }
View Full Code Here

Examples of org.apache.isis.core.metamodel.facets.actions.command.CommandFacet.persistence()

                // copy over the command execution 'context' (if available)
                final CommandFacet commandFacet = getFacetHolder().getFacet(CommandFacet.class);
                if(commandFacet != null && !commandFacet.isDisabled()) {
                    command.setExecuteIn(commandFacet.executeIn());
                    command.setPersistence(commandFacet.persistence());
                } else {
                    // if no facet, assume do want to execute right now, but only persist (eventually) if hinted.
                    command.setExecuteIn(ExecuteIn.FOREGROUND);
                    command.setPersistence(Persistence.IF_HINTED);
                }
View Full Code Here

Examples of org.apache.isis.core.metamodel.facets.actions.command.CommandFacet.persistence()

                // copy over the command execution 'context' (if available)
                final CommandFacet commandFacet = getFacetHolder().getFacet(CommandFacet.class);
                if(commandFacet != null && !commandFacet.isDisabled()) {
                    command.setExecuteIn(commandFacet.executeIn());
                    command.setPersistence(commandFacet.persistence());
                } else {
                    // if no facet, assume do want to execute right now, but only persist (eventually) if hinted.
                    command.setExecuteIn(org.apache.isis.applib.annotation.Command.ExecuteIn.FOREGROUND);
                    command.setPersistence(org.apache.isis.applib.annotation.Command.Persistence.IF_HINTED);
                }
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

            .dataColumnName("DATA").dataColumnType("VARBINARY(1000)")
            .timestampColumnName("TIMESTAMP").timestampColumnType("BIGINT")
            .dataSource()
            .jndiUrl("java:jboss/datasources/ExampleDS");
      Configuration build = bld.build();
      JdbcMixedStoreConfiguration sc = (JdbcMixedStoreConfiguration) build.persistence().stores().get(0);
      Assert.assertEquals(sc.databaseType(), DatabaseType.MYSQL);
      Assert.assertEquals(sc.binaryTable().databaseType(), DatabaseType.MYSQL);
      Assert.assertEquals(sc.stringTable().databaseType(), DatabaseType.MYSQL);
   }
}
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

   public void testImplicitPooledConnectionFactory() {
      ConfigurationBuilder b = new ConfigurationBuilder();
      b.persistence().addStore(JdbcBinaryStoreConfigurationBuilder.class)
         .connectionPool().connectionUrl(JDBC_URL);
      Configuration configuration = b.build();
      JdbcBinaryStoreConfiguration store = (JdbcBinaryStoreConfiguration) configuration.persistence().stores().get(0);
      assert store.connectionFactory() instanceof PooledConnectionFactoryConfiguration;
   }

   public void testImplicitManagedConnectionFactory() {
      ConfigurationBuilder b = new ConfigurationBuilder();
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

   public void testImplicitManagedConnectionFactory() {
      ConfigurationBuilder b = new ConfigurationBuilder();
      b.persistence().addStore(JdbcBinaryStoreConfigurationBuilder.class)
         .dataSource().jndiUrl("java:jboss/datasources/ExampleDS");
      Configuration configuration = b.build();
      JdbcBinaryStoreConfiguration store = (JdbcBinaryStoreConfiguration) configuration.persistence().stores().get(0);
      assert store.connectionFactory() instanceof ManagedConnectionFactoryConfiguration;
   }

   public void testJdbcBinaryCacheStoreConfigurationAdaptor() {
      ConfigurationBuilder b = new ConfigurationBuilder();
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

            .idColumnName("id").idColumnType("VARCHAR")
            .dataColumnName("datum").dataColumnType("BINARY")
            .timestampColumnName("version").timestampColumnType("BIGINT")
         .async().enable();
      Configuration configuration = b.build();
      JdbcBinaryStoreConfiguration store = (JdbcBinaryStoreConfiguration) configuration.persistence().stores().get(0);
      assert store.connectionFactory() instanceof PooledConnectionFactoryConfiguration;
      assert ((PooledConnectionFactoryConfiguration)store.connectionFactory()).connectionUrl().equals(JDBC_URL);
      assert store.table().tableNamePrefix().equals("BINARY_");
      assert store.table().idColumnName().equals("id");
      assert store.table().idColumnType().equals("VARCHAR");
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

      assert store.async().enabled();

      b = new ConfigurationBuilder();
      b.persistence().addStore(JdbcBinaryStoreConfigurationBuilder.class).read(store);
      Configuration configuration2 = b.build();
      JdbcBinaryStoreConfiguration store2 = (JdbcBinaryStoreConfiguration) configuration2.persistence().stores().get(0);
      assert store2.connectionFactory() instanceof PooledConnectionFactoryConfiguration;
      assert ((PooledConnectionFactoryConfiguration)store2.connectionFactory()).connectionUrl().equals(JDBC_URL);
      assert store2.table().tableNamePrefix().equals("BINARY_");
      assert store2.table().idColumnName().equals("id");
      assert store2.table().idColumnType().equals("VARCHAR");
View Full Code Here

Examples of org.infinispan.configuration.cache.Configuration.persistence()

         .idColumnName("id").idColumnType("VARCHAR")
         .dataColumnName("datum").dataColumnType("BINARY")
         .timestampColumnName("version").timestampColumnType("BIGINT");

      Configuration configuration = b.build();
      JdbcMixedStoreConfiguration store = (JdbcMixedStoreConfiguration) configuration.persistence().stores().get(0);
      assert store.connectionFactory() instanceof PooledConnectionFactoryConfiguration;
      assert ((PooledConnectionFactoryConfiguration)store.connectionFactory()).connectionUrl().equals(JDBC_URL);
      assert store.binaryTable().tableNamePrefix().equals("BINARY_");
      assert store.binaryTable().idColumnName().equals("id");
      assert store.binaryTable().idColumnType().equals("VARCHAR");
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.