Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[hotfix][table] Add objectReuse parameter for AsyncLookupJoinITCase. #19728

Merged
merged 2 commits into from May 17, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -38,7 +38,10 @@ import java.util.{Collection => JCollection}
import scala.collection.JavaConversions._

@RunWith(classOf[Parameterized])
class AsyncLookupJoinITCase(legacyTableSource: Boolean, backend: StateBackendMode)
class AsyncLookupJoinITCase(
legacyTableSource: Boolean,
backend: StateBackendMode,
objectReuse: Boolean)
extends StreamingWithStateTestBase(backend) {

val data = List(
Expand All @@ -53,9 +56,11 @@ class AsyncLookupJoinITCase(legacyTableSource: Boolean, backend: StateBackendMod
@Before
override def before(): Unit = {
super.before()
// TODO: remove this until [FLINK-12351] is fixed.
// currently AsyncWaitOperator doesn't copy input element which is a bug
env.getConfig.disableObjectReuse()
if (objectReuse) {
env.getConfig.enableObjectReuse()
} else {
env.getConfig.disableObjectReuse()
}

createScanTable("src", data)
createLookupTable("user_table", userData)
Expand Down Expand Up @@ -298,13 +303,13 @@ class AsyncLookupJoinITCase(legacyTableSource: Boolean, backend: StateBackendMod
}

object AsyncLookupJoinITCase {
@Parameterized.Parameters(name = "LegacyTableSource={0}, StateBackend={1}")
@Parameterized.Parameters(name = "LegacyTableSource={0}, StateBackend={1}, ObjectReuse={2}")
def parameters(): JCollection[Array[Object]] = {
Seq[Array[AnyRef]](
Array(JBoolean.TRUE, HEAP_BACKEND),
Array(JBoolean.TRUE, ROCKSDB_BACKEND),
Array(JBoolean.FALSE, HEAP_BACKEND),
Array(JBoolean.FALSE, ROCKSDB_BACKEND)
Array(JBoolean.TRUE, HEAP_BACKEND, JBoolean.TRUE),
Array(JBoolean.TRUE, ROCKSDB_BACKEND, JBoolean.FALSE),
Array(JBoolean.FALSE, HEAP_BACKEND, JBoolean.FALSE),
Array(JBoolean.FALSE, ROCKSDB_BACKEND, JBoolean.TRUE)
)
}
}