'Union of Different Types of stream in Flink by BaseType
Can We have union of two different type of stream but they having common base type ? For example for say The order events comes like
OrderEvent: extends Event
{
userId: Int
Shape:
Color:
qty:
string name(); //return orderEvent
}
And tick event be like
TickEvent: extends Event
{
Shape:
Color:
Price:
Location:
string name() //return tickEvent
}
Considering both are some kind of event, what if I have a Event class from which all the events are derived from. The event class would look like
Event:
{
Shape:
Color:
string name(); //return event
}
Can we join these stream by union ? like
DataStream<Event> eventStream = orderStream.union(tickstream);
And when I receive these event in a operator I use name method to find which type of event it is and do the processing accordingly ?
Solution 1:[1]
Would be easier to combine these using Flink's existing Either class.
Solution 2:[2]
You could just map your OrderEvent and TickEvent streams to Event streams and then union them, like:
DataStream<Event> eventDataStream = orderStream
.map((MapFunction<OrderEvent, Event>) event -> event)
.union(tickStream.map((MapFunction<TickEvent, Event>) event -> event));
Solution 3:[3]
We likely need more information in order to answer your question accurately.
I'd guess this is not possible since the .aab or .apk is the bundled code. React Native runs on the JS Core engine. I'm struggling to see why you would want to know this though within your application as you should be using the Android App Bundle OR submitting with the APK, not a mix of both.
Indeed in Google Play once you've enabled Managed Signing (to use the .aab) then I don't think you can go back to using the .apk files.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | kkrugler |
| Solution 2 | TechnoX |
| Solution 3 | P. Brew |
