hooliooo
10/23/2020, 12:56 PMval inputStream: InputStream = URL(attachmentURL).openStream()
val buffer = DataBufferUtils.readInputStream(
{ inputStream },
DefaultDataBufferFactory(),
8192
)
I’ve integrated the following dependency into my project:
implementation(group = "io.projectreactor", name = "reactor-core", version = "3.3.10.RELEASE")
But i’m getting this error:
Cannot access class 'reactor.core.publisher.Flux'. Check your module classpath for missing or conflicting dependencies
highlighted on readInputStream
Am I missing something?hooliooo
10/23/2020, 1:10 PM/**
* Obtain a {@link InputStream} from the given supplier, and read it into a
* {@code Flux} of {@code DataBuffer}s. Closes the input stream when the
* Flux is terminated.
* @param inputStreamSupplier the supplier for the input stream to read from
* @param bufferFactory the factory to create data buffers with
* @param bufferSize the maximum size of the data buffers
* @return a Flux of data buffers read from the given channel
*/
public static Flux<DataBuffer> readInputStream(
Callable<InputStream> inputStreamSupplier, DataBufferFactory bufferFactory, int bufferSize) {
Assert.notNull(inputStreamSupplier, "'inputStreamSupplier' must not be null");
return readByteChannel(() -> Channels.newChannel(inputStreamSupplier.call()), bufferFactory, bufferSize);
}
No idea what’s happening here:ashmelev
10/23/2020, 2:05 PMashmelev
10/23/2020, 2:06 PMashmelev
10/23/2020, 2:09 PMashmelev
10/23/2020, 2:10 PMspring-boot-starter-webflux
on the class path, having removed ...-web
ashmelev
10/28/2020, 1:38 PMFlux
in my project was due to a mis-placement of the Coroutines Reactor dependency in the gradle build file (I have multi-module project and I had added to one sub-project and not another).ashmelev
10/28/2020, 1:41 PMashmelev
10/28/2020, 1:41 PMashmelev
10/28/2020, 1:44 PMkeycloak-spring-starter
library dependes on spring-boot-starter-web:2.0.5
for some reason. WebFlux won't bind properly if the -web
dependency is present.
Excluding the ``spring-boot-starter-web:2.0.5` library from the gradle build resulting in many missing references.ashmelev
10/28/2020, 1:45 PM