Package com.foundationdb.server.explain.format

Examples of com.foundationdb.server.explain.format.DefaultFormatter


    }

    protected String withIndentedExplain(StringBuilder str, ExplainContext context, String defaultSchemaName, DefaultFormatter.LevelOfDetail levelOfDetail) {
        if (context == null)
            context = new ExplainContext(); // Empty
        DefaultFormatter f = new DefaultFormatter(defaultSchemaName, levelOfDetail);
        for (String operator : f.format(plannable.getExplainer(context))) {
            str.append("\n  ");
            str.append(operator);
        }
        return str.toString();
    }
View Full Code Here


                new UpsertRowUpdateFunction(Arrays.asList(updates), stream.rowType);
        stream.operator = API.update_Returning(stream.operator, updateFunction);
       
        if (logger.isDebugEnabled()) {
            ExplainContext explain = explainUpdateStatement(stream.operator, table, Arrays.asList(updates));
            DefaultFormatter formatter = new DefaultFormatter(table.getName().getSchemaName());
            logger.debug("Update Plan for {}:\n{}", table,
                         join(formatter.format(stream.operator.getExplainer(explain))));
        }
        return stream.operator;
    }
View Full Code Here

                break;
            case VERBOSE:
                detail = DefaultFormatter.LevelOfDetail.VERBOSE;
                break;
            }
            DefaultFormatter f = new DefaultFormatter(server.getDefaultSchemaName(), detail);
            explain = f.format(explainable.getExplainer(context.getExplainContext()));
        }
        init(explain);
        compiler = null;
        return this;
    }
View Full Code Here

            }
        });
        plan = API.filter_Default(plan, keepTypes);

        if (logger.isDebugEnabled()) {
            DefaultFormatter formatter = new DefaultFormatter(table.getName().getSchemaName());
            logger.debug("Scan Plan for {}:\n{}", table, join(formatter.format(plan.getExplainer(new ExplainContext()))));

        }

        return plan;
       
View Full Code Here

        Operator plan = API.groupLookup_Default(scan, table.getGroup(),
                                                scanType, tableTypes,
                                                API.InputPreservationOption.DISCARD_INPUT, 1);
                                       
        if (logger.isDebugEnabled()) {
            DefaultFormatter formatter = new DefaultFormatter(table.getName().getSchemaName());
            logger.debug("Branch Plan for {}:\n{}", table,
                         join(formatter.format(plan.getExplainer(new ExplainContext()))));
        }
        return plan;
    }
View Full Code Here

                indexType,
                ancestorType,
                API.InputPreservationOption.DISCARD_INPUT,
                1);
        if (logger.isDebugEnabled()) {
            DefaultFormatter formatter = new DefaultFormatter(table.getName().getSchemaName());
            logger.debug("Ancestor Plan for {}:\n{}", table,
                         join(formatter.format(lookup.getExplainer(new ExplainContext()))));
        }
        return lookup;
    }
View Full Code Here

            }
            context.putExtraInfo(plan.plannable,
                                 new CompoundExplainer(Type.EXTRA_INFO, atts));
            Explainer explainer = plan.plannable.getExplainer(context);
            LOG.debug("Plan for " + foreignKey.getConstraintName().getTableName() + ":\n" +
                      Strings.join(new DefaultFormatter(tableName.getSchemaName()).format(explainer)));
        }
        return plan;
    }
View Full Code Here

    }

    protected String getExplain (Operator plannable, String defaultSchemaName) {
        StringBuilder str = new StringBuilder();
        ExplainContext context = new ExplainContext(); // Empty
        DefaultFormatter f = new DefaultFormatter(defaultSchemaName);
        for (String operator : f.format(plannable.getExplainer(context))) {
            if(str.length() > 0) {
                str.append("\n");
            }
            str.append(operator);
        }
View Full Code Here

    }

    protected String getExplain (Operator plannable, String defaultSchemaName) {
        StringBuilder str = new StringBuilder();
        ExplainContext context = new ExplainContext(); // Empty
        DefaultFormatter f = new DefaultFormatter(defaultSchemaName);
        for (String operator : f.format(plannable.getExplainer(context))) {
            str.append("\n  ");
            str.append(operator);
        }
        return str.toString();
    }
View Full Code Here

TOP

Related Classes of com.foundationdb.server.explain.format.DefaultFormatter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.