package com.lanyuanxiaoyao.service.executor.task.functions.police;

import com.lanyuanxiaoyao.service.executor.task.entity.Prisoner;
import org.apache.flink.api.common.functions.RichReduceFunction;
import org.eclipse.collections.api.factory.Lists;
import org.eclipse.collections.api.multimap.MutableMultimap;

/**
 * @author lanyuanxiaoyao
 */
public class PrimaryKeyReduce extends RichReduceFunction<Prisoner> {
    private final MutableMultimap<String, Prisoner> CACHE;

    public PrimaryKeyReduce() {
        CACHE = Lists.mutable.<Prisoner>empty()
                .groupBy(Prisoner::getKey);
    }

    @Override
    public Prisoner reduce(Prisoner value1, Prisoner value2) throws Exception {
        return null;
    }
}
