(String[] cmdTokens)
| 1158 | } |
| 1159 | |
| 1160 | @Override |
| 1161 | protected void processFsCommand(String[] cmdTokens) throws IOException { |
| 1162 | filter.validate(PigCommandFilter.Command.FS); |
| 1163 | for (int i = 0 ; i < cmdTokens.length ; i++) { |
| 1164 | cmdTokens[i] = parameterSubstitutionInGrunt(cmdTokens[i]); |
| 1165 | } |
| 1166 | if(mExplain == null) { // process only if not in "explain" mode |
| 1167 | |
| 1168 | executeBatch(); |
| 1169 | |
| 1170 | int retCode = -1; |
| 1171 | |
| 1172 | try { |
| 1173 | retCode = shell.run(cmdTokens); |
| 1174 | } catch (Exception e) { |
| 1175 | throw new IOException(e); |
| 1176 | } |
| 1177 | |
| 1178 | if (retCode != 0 && !mInteractive) { |
| 1179 | String s = LoadFunc.join( |
| 1180 | (AbstractList<String>) Arrays.asList(cmdTokens), " "); |
| 1181 | throw new IOException("fs command '" + s |
| 1182 | + "' failed. Please check output logs for details"); |
| 1183 | } |
| 1184 | } else { |
| 1185 | log.warn("'fs' statement is ignored while processing 'explain -script' or '-check'"); |
| 1186 | } |
| 1187 | } |
| 1188 | |
| 1189 | @Override |
| 1190 | protected void processShCommand(String[] cmdTokens) throws IOException { |
nothing calls this directly
no test coverage detected