question: private void generateFlow ( ACLRule rule , String dpid , String flowName ) { int priority ; if ( dpid2FlowPriority . get ( dpid ) == null ) { dpid2FlowPriority . put ( dpid , 30000 ) ; priority = 30000 ; } else { priority = dpid2FlowPriority . get ( dpid ) ; } if ( rule . getNw_src ( ) != null ) { HashMap < String , Object > flow = new HashMap < String , Object > ( ) ; flow . put ( StaticFlowEntryPusher . COLUMN_SWITCH , dpid ) ; flow . put ( StaticFlowEntryPusher . COLUMN_NAME , flowName ) ; flow . put ( StaticFlowEntryPusher . COLUMN_ACTIVE , Boolean . toString ( true ) ) ; flow . put ( StaticFlowEntryPusher . COLUMN_COOKIE , "0" ) ; flow . put ( StaticFlowEntryPusher . COLUMN_PRIORITY , Integer . toString ( priority ) ) ; dpid2FlowPriority . put ( dpid , -- priority ) ; flow . put ( StaticFlowEntryPusher . COLUMN_DL_TYPE , "2048" ) ; flow . put ( StaticFlowEntryPusher . COLUMN_NW_SRC , rule . getNw_src ( ) ) ; if ( rule . getNw_dst ( ) != null ) { flow . put ( StaticFlowEntryPusher . COLUMN_NW_DST , rule . getNw_dst ( ) ) ; } if ( rule . getNw_proto ( ) != 0 ) { flow . put ( StaticFlowEntryPusher . COLUMN_NW_PROTO , Integer . toString ( rule . getNw_proto ( ) ) ) ; } if ( rule . getAction ( ) == Action . ALLOW ) { flow . put ( StaticFlowEntryPusher . COLUMN_ACTIONS , "output=controller" ) ; } if ( rule . getTp_dst ( ) != 0 ) { flow . put ( StaticFlowEntryPusher . COLUMN_TP_DST , Integer . toString ( rule . getTp_dst ( ) ) ) ; } storageSource . insertRowAsync ( StaticFlowEntryPusher . TABLE_NAME , flow ) ; } else { HashMap < String , Object > flow = new HashMap < String , Object > ( ) ; flow . put ( StaticFlowEntryPusher . COLUMN_SWITCH , dpid ) ; flow . put ( StaticFlowEntryPusher . COLUMN_NAME , flowName ) ; flow . put ( StaticFlowEntryPusher . COLUMN_ACTIVE , Boolean . toString ( true ) ) ; flow . put ( StaticFlowEntryPusher . COLUMN_COOKIE , "0" ) ; flow . put ( StaticFlowEntryPusher . COLUMN_PRIORITY , Integer . toString ( priority ) ) ; dpid2FlowPriority . put ( dpid , -- priority ) ; flow . put ( StaticFlowEntryPusher . COLUMN_DL_TYPE , "2048" ) ; flow . put ( StaticFlowEntryPusher . COLUMN_NW_DST , rule . getNw_dst ( ) ) ; if ( rule . getNw_proto ( ) != 0 ) { flow . put ( StaticFlowEntryPusher . COLUMN_NW_PROTO , Integer . toString ( rule . getNw_proto ( ) ) ) ; } if ( rule . getAction ( ) == Action . ALLOW ) { flow . put ( StaticFlowEntryPusher . COLUMN_ACTIONS , "output=controller" ) ; } if ( rule . getTp_dst ( ) != 0 ) { flow . put ( StaticFlowEntryPusher . COLUMN_TP_DST , Integer . toString ( rule . getTp_dst ( ) ) ) ; } storageSource . insertRowAsync ( StaticFlowEntryPusher . TABLE_NAME , flow ) ; } logger . info ( "ACL flow " + flowName + " added in " + dpid ) ; }
target:  generate and push ACL flow entry