MCPcopy Create free account
hub / github.com/OWASP/Python-Honeypot / aggregate_function

Function aggregate_function

api/utility.py:218–234  ·  view source on GitHub ↗

uses aggregate function of mongodb Args : data connection object on which to aggregate on aggregated query in a list Returns: the aggregated data in a list

(data_connection, agr_query)

Source from the content-addressed store, hash-verified

216
217
218def aggregate_function(data_connection, agr_query):
219 """
220 uses aggregate function of mongodb
221
222 Args :
223 data connection object on which to aggregate on
224 aggregated query in a list
225
226 Returns:
227 the aggregated data in a list
228 """
229 return list(
230 data_connection.aggregate(
231 agr_query,
232 allowDiskUse=True
233 )
234 )

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected