List of usage examples for org.springframework.integration.ip.tcp.connection TcpNioClientConnectionFactory setSingleUse
public void setSingleUse(boolean singleUse)
From source file:com.acmemotors.Main.java
@Bean public TcpNioClientConnectionFactory connectionFactory(@Value("${dongleHost:192.168.0.10}") String dongleHost, @Value("${donglePort:35000}") int donglePort) { TcpNioClientConnectionFactory factory; factory = new TcpNioClientConnectionFactory(dongleHost, donglePort); OBD2Serializer odb2Serializer = new OBD2Serializer(); factory.setSerializer(odb2Serializer); factory.setDeserializer(odb2Serializer); factory.setSingleUse(false); factory.afterPropertiesSet();/*from w w w .ja v a 2s. com*/ return factory; }