Search in sources :

Example 11 with MarshallingConfiguration

use of org.jboss.marshalling.MarshallingConfiguration in project netty by netty.

the class SerialCompatibleMarshallingDecoderTest method createMarshallingConfig.

@Override
protected MarshallingConfiguration createMarshallingConfig() {
    // Create a configuration
    final MarshallingConfiguration configuration = new MarshallingConfiguration();
    configuration.setVersion(5);
    return configuration;
}
Also used : MarshallingConfiguration(org.jboss.marshalling.MarshallingConfiguration)

Example 12 with MarshallingConfiguration

use of org.jboss.marshalling.MarshallingConfiguration in project netty by netty.

the class SerialCompatibleMarshallingEncoderTest method createMarshallingConfig.

@Override
protected MarshallingConfiguration createMarshallingConfig() {
    // Create a configuration
    final MarshallingConfiguration configuration = new MarshallingConfiguration();
    configuration.setVersion(5);
    return configuration;
}
Also used : MarshallingConfiguration(org.jboss.marshalling.MarshallingConfiguration)

Example 13 with MarshallingConfiguration

use of org.jboss.marshalling.MarshallingConfiguration in project wildfly by wildfly.

the class DatabaseTimerPersistence method start.

@Override
public void start(final StartContext context) throws StartException {
    factory = new RiverMarshallerFactory();
    configuration = new MarshallingConfiguration();
    configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoader.getValue()));
    managedReference = dataSourceInjectedValue.getValue().getReference();
    dataSource = (DataSource) managedReference.getInstance();
    final InputStream stream = DatabaseTimerPersistence.class.getClassLoader().getResourceAsStream("timer-sql.properties");
    sql = new Properties();
    try {
        sql.load(stream);
    } catch (IOException e) {
        throw new StartException(e);
    } finally {
        safeClose(stream);
    }
    extractDialects();
    investigateDialect();
    checkDatabase();
    if (refreshInterval > 0) {
        refreshTask = new RefreshTask();
        timerInjectedValue.getValue().schedule(refreshTask, refreshInterval, refreshInterval);
    }
}
Also used : MarshallingConfiguration(org.jboss.marshalling.MarshallingConfiguration) ByteArrayInputStream(java.io.ByteArrayInputStream) InputStream(java.io.InputStream) RiverMarshallerFactory(org.jboss.marshalling.river.RiverMarshallerFactory) StartException(org.jboss.msc.service.StartException) IOException(java.io.IOException) Properties(java.util.Properties)

Aggregations

MarshallingConfiguration (org.jboss.marshalling.MarshallingConfiguration)13 EmbeddedChannel (io.netty.channel.embedded.EmbeddedChannel)4 MarshallerFactory (org.jboss.marshalling.MarshallerFactory)4 RiverMarshallerFactory (org.jboss.marshalling.river.RiverMarshallerFactory)4 Test (org.junit.Test)4 ByteArrayOutputStream (java.io.ByteArrayOutputStream)3 Marshaller (org.jboss.marshalling.Marshaller)3 ByteBuf (io.netty.buffer.ByteBuf)2 IOException (java.io.IOException)2 StartException (org.jboss.msc.service.StartException)2 ZeroPortPolicy (com.sun.corba.se.spi.extension.ZeroPortPolicy)1 ChannelHandler (io.netty.channel.ChannelHandler)1 ByteArrayInputStream (java.io.ByteArrayInputStream)1 File (java.io.File)1 InputStream (java.io.InputStream)1 ArrayList (java.util.ArrayList)1 Properties (java.util.Properties)1 TransactionManager (javax.transaction.TransactionManager)1 EJBComponent (org.jboss.as.ejb3.component.EJBComponent)1 StatelessSessionComponent (org.jboss.as.ejb3.component.stateless.StatelessSessionComponent)1