public void setProfileDepth(int profileDepth) {
        this.profileDepth = profileDepth;
        profiling.getMatching().setDepth(profileDepth);
        profiling.getFirstPhaseRanking().setDepth(profileDepth);
        profiling.getSecondPhaseRanking().setDepth(profileDepth);
    }
Sets the profiling depth. Profiling enabled if non-zero. Higher numbers means increasingly more detail.
container-search/src/main/java/com/yahoo/search/query/Trace.java