[ https://issues.apache.org/jira/browse/SOLR-7830?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17508767#comment-17508767 ]
Michael Gibney commented on SOLR-7830: -------------------------------------- Thanks so much for sharing; this looks pretty straightforward! {quote}The downside of using this in a plugin is that it's not as convenient to use in json faceting, you have to use it in its function form e.g. facet: \{ "sampledocument":"topdocs(null,0,2)" } {quote} I'm a bit confused about this statement; I'm not sure what other way you would envision this being invoked, and under what alternative circumstances. IIUC if this were to be merged into core solr, one would invoke the function in exactly the same way in the facet request, no? Did you mean to say that {{"sampledocument":"topdocs(null,0,2)"}} would _not_ work with the plugin approach, and you'd need `facet: \{ type:func, func:topdocs, ... }` full syntax instead? (I don't know enough to say one way or the other whether that _would_ be the case, but it seems plausible). > topdocs facet function > ---------------------- > > Key: SOLR-7830 > URL: https://issues.apache.org/jira/browse/SOLR-7830 > Project: Solr > Issue Type: New Feature > Components: Facet Module > Reporter: Yonik Seeley > Priority: Major > Attachments: ALT-SOLR-7830.patch, SOLR-7830.patch, SOLR-7830.patch, > TopDocsAgg.java > > > A topdocs() facet function would return the top N documents per facet bucket. > This would be a big step toward unifying grouping and the new facet module. -- This message was sent by Atlassian Jira (v8.20.1#820001) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org