You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@samza.apache.org by "Alan Zhang (Jira)" <ji...@apache.org> on 2020/06/11 16:47:00 UTC
[jira] [Resolved] (SAMZA-2547) Add missing "tableId" for
SendToTableOperatorSpec in Samza job execution plan
[ https://issues.apache.org/jira/browse/SAMZA-2547?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Alan Zhang resolved SAMZA-2547.
-------------------------------
Resolution: Fixed
> Add missing "tableId" for SendToTableOperatorSpec in Samza job execution plan
> -----------------------------------------------------------------------------
>
> Key: SAMZA-2547
> URL: https://issues.apache.org/jira/browse/SAMZA-2547
> Project: Samza
> Issue Type: Bug
> Reporter: Alan Zhang
> Assignee: Alan Zhang
> Priority: Major
> Time Spent: 40m
> Remaining Estimate: 0h
>
> Currently, JobGraphJsonGenerator.operatorToMap() function populates "tableId" field when the given operator spec is table related.
> However, as shown in the below codes, we forgot to handle *SendToTableOperatorSpec*, but handle *StreamTableJoinOperatorSpec* twice somehow.
> {code:java}
> private Map<String, Object> operatorToMap(OperatorSpec spec) {
> Map<String, Object> map = new HashMap<>();
> map.put("opCode", spec.getOpCode().name());
> map.put("opId", spec.getOpId());
> map.put("sourceLocation", spec.getSourceLocation());
> ...
> if (spec instanceof StreamTableJoinOperatorSpec) {
> String tableId = ((StreamTableJoinOperatorSpec) spec).getTableId();
> map.put("tableId", tableId);
> }
> if (spec instanceof StreamTableJoinOperatorSpec) {
> String tableId = ((StreamTableJoinOperatorSpec) spec).getTableId();
> map.put("tableId", tableId);
> }
> if (spec instanceof JoinOperatorSpec) {
> map.put("ttlMs", ((JoinOperatorSpec) spec).getTtlMs());
> }
> return map;
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)