Package com.atlan.model.search
Class SearchLogRequest
java.lang.Object
com.atlan.model.core.AtlanObject
com.atlan.model.search.SearchLogRequest
- All Implemented Interfaces:
Serializable
Class from which to configure and run a search against Atlan's log of past searches.
For a list of the attributes that can be searched, aggregated, sorted, etc see the
static constants in
SearchLogEntry
.- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
SearchLogRequest.SearchLogRequestBuilder<C extends SearchLogRequest,
B extends SearchLogRequest.SearchLogRequestBuilder<C, B>> Nested classes/interfaces inherited from class com.atlan.model.core.AtlanObject
AtlanObject.AtlanObjectBuilder<C extends AtlanObject,
B extends AtlanObject.AtlanObjectBuilder<C, B>> -
Field Summary
Modifier and TypeFieldDescriptionstatic final co.elastic.clients.elasticsearch._types.query_dsl.Query
static final co.elastic.clients.elasticsearch._types.query_dsl.Query
Fields inherited from class com.atlan.model.core.AtlanObject
rawJsonObject
-
Constructor Summary
ModifierConstructorDescriptionprotected
-
Method Summary
Modifier and TypeMethodDescriptionstatic SearchLogRequest.SearchLogRequestBuilder<?,
?> static SearchLogRequest.SearchLogRequestBuilder<?,
?> builder
(co.elastic.clients.elasticsearch._types.query_dsl.Query query) Build a search using the provided query and default options.static SearchLogRequest.SearchLogRequestBuilder<?,
?> builder
(IndexSearchDSL dsl) Build a search using the provided DSL and default options.protected boolean
long
count()
Return the total number of search log entries that will match the supplied criteria, using the most minimal query possible (retrieves minimal data).long
count
(AtlanClient client) Return the total number of search log entries that will match the supplied criteria, using the most minimal query possible (retrieves minimal data).boolean
getDsl()
Parameters for the search itself.int
hashCode()
mostRecentViewers
(AtlanClient client, String guid, int maxUsers) Find the most recent viewers of the asset in Atlan.mostRecentViewers
(AtlanClient client, String guid, int maxUsers, List<String> excludeUsers) Find the most recent viewers of the asset in Atlan.mostRecentViewers
(String guid, int maxUsers) Find the most recent viewers of the asset in Atlan.mostRecentViewers
(String guid, int maxUsers, List<String> excludeUsers) Find the most recent viewers of the asset in Atlan.static List<AssetViews>
mostViewedAssets
(int maxAssets, boolean byDifferentUsers) Find the most-viewed assets in Atlan.static List<AssetViews>
mostViewedAssets
(int maxAssets, boolean byDifferentUsers, List<String> excludeUsers) Find the most-viewed assets in Atlan.static List<AssetViews>
mostViewedAssets
(AtlanClient client, int maxAssets, boolean byDifferentUsers) Find the most-viewed assets in Atlan.static List<AssetViews>
mostViewedAssets
(AtlanClient client, int maxAssets, boolean byDifferentUsers, List<String> excludeUsers) Find the most-viewed assets in Atlan.search()
Run the search.search
(AtlanClient client) Run the search.static SearchLogRequest.SearchLogRequestBuilder<?,
?> searches()
Start building a search log request for searches run against assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> searches
(long from, long to) Start building a search log request for searches run against assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> Start building a search log request for searches run against assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> Start building a search log request for searches run against assets.stream()
Run the search to retrieve entries that match the supplied criteria.stream
(boolean parallel) Run the search to retrieve entries that match the supplied criteria.stream
(AtlanClient client) Run the search to retrieve entries that match the supplied criteria.stream
(AtlanClient client, boolean parallel) Run the search to retrieve entries that match the supplied criteria.toString()
static SearchLogRequest.SearchLogRequestBuilder<?,
?> views()
Start building a search log request for the views of assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> views
(long from, long to) Start building a search log request for the views of assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> Start building a search log request for the views of assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> Start building a search log request for the views of assets.static SearchLogRequest.SearchLogRequestBuilder<?,
?> viewsByGuid
(String guid) Start building a search log request for the views of an asset, by its GUID.static SearchLogRequest.SearchLogRequestBuilder<?,
?> viewsByGuid
(String guid, List<String> excludeUsers) Start building a search log request for the views of an asset, by its GUID.Methods inherited from class com.atlan.model.core.AtlanObject
getRawJsonObject, setRawJsonObject, toJson
-
Field Details
-
EXCLUDE_USERS
-
VIEWED
public static final co.elastic.clients.elasticsearch._types.query_dsl.Query VIEWED -
SEARCHED
public static final co.elastic.clients.elasticsearch._types.query_dsl.Query SEARCHED
-
-
Constructor Details
-
SearchLogRequest
-
-
Method Details
-
builder
public static SearchLogRequest.SearchLogRequestBuilder<?,?> builder(co.elastic.clients.elasticsearch._types.query_dsl.Query query) Build a search using the provided query and default options.- Parameters:
query
- the query to use for the search- Returns:
- the search request, with default options
-
builder
Build a search using the provided DSL and default options.- Parameters:
dsl
- the query details to use for the search- Returns:
- the search request, with default options
-
views
Start building a search log request for the views of assets.- Returns:
- a request builder pre-configured with these criteria
-
views
Start building a search log request for the views of assets.- Parameters:
excludeUsers
- list of usernames to exclude from the results- Returns:
- a request builder pre-configured with these criteria
-
views
Start building a search log request for the views of assets.- Parameters:
from
- timestamp after which to look for any asset view activity (inclusive)to
- timestamp up through which to look for any asset view activity (inclusive)- Returns:
- a request builder pre-configured with these criteria
-
views
public static SearchLogRequest.SearchLogRequestBuilder<?,?> views(long from, long to, List<String> excludeUsers) Start building a search log request for the views of assets.- Parameters:
from
- timestamp after which to look for any asset view activity (inclusive)to
- timestamp up through which to look for any asset view activity (inclusive)excludeUsers
- list of usernames to exclude from the results- Returns:
- a request builder pre-configured with these criteria
-
searches
Start building a search log request for searches run against assets.- Returns:
- a request builder pre-configured with these criteria
-
searches
Start building a search log request for searches run against assets.- Parameters:
excludeUsers
- list of usernames to exclude from the results- Returns:
- a request builder pre-configured with these criteria
-
searches
Start building a search log request for searches run against assets.- Parameters:
from
- timestamp after which to look for any search activity (inclusive)to
- timestamp up through which to look for any search activity (inclusive)- Returns:
- a request builder pre-configured with these criteria
-
searches
public static SearchLogRequest.SearchLogRequestBuilder<?,?> searches(long from, long to, List<String> excludeUsers) Start building a search log request for searches run against assets.- Parameters:
from
- timestamp after which to look for any search activity (inclusive)to
- timestamp up through which to look for any search activity (inclusive)excludeUsers
- list of usernames to exclude from the results- Returns:
- a request builder pre-configured with these criteria
-
viewsByGuid
Start building a search log request for the views of an asset, by its GUID.- Parameters:
guid
- unique identifier of the asset for which to retrieve the view history- Returns:
- a request builder pre-configured with these criteria
-
viewsByGuid
public static SearchLogRequest.SearchLogRequestBuilder<?,?> viewsByGuid(String guid, List<String> excludeUsers) Start building a search log request for the views of an asset, by its GUID.- Parameters:
guid
- unique identifier of the asset for which to retrieve the view historyexcludeUsers
- list of usernames to exclude from the results- Returns:
- a request builder pre-configured with these criteria
-
mostRecentViewers
Find the most recent viewers of the asset in Atlan.- Parameters:
guid
- of the assetmaxUsers
- maximum number of recent users to consider- Returns:
- the list of users that most-recently viewed the asset, in descending order (most-recently viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostRecentViewers
public static List<UserViews> mostRecentViewers(String guid, int maxUsers, List<String> excludeUsers) throws AtlanException Find the most recent viewers of the asset in Atlan.- Parameters:
guid
- of the assetmaxUsers
- maximum number of recent users to considerexcludeUsers
- list of usernames to exclude from the results- Returns:
- the list of users that most-recently viewed the asset, in descending order (most-recently viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostRecentViewers
public static List<UserViews> mostRecentViewers(AtlanClient client, String guid, int maxUsers) throws AtlanException Find the most recent viewers of the asset in Atlan.- Parameters:
client
- connectivity to the Atlan tenant on which to run the searchguid
- of the assetmaxUsers
- maximum number of recent users to consider- Returns:
- the list of users that most-recently viewed the asset, in descending order (most-recently viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostRecentViewers
public static List<UserViews> mostRecentViewers(AtlanClient client, String guid, int maxUsers, List<String> excludeUsers) throws AtlanException Find the most recent viewers of the asset in Atlan.- Parameters:
client
- connectivity to the Atlan tenant on which to run the searchguid
- of the assetmaxUsers
- maximum number of recent users to considerexcludeUsers
- list of usernames to exclude from the results- Returns:
- the list of users that most-recently viewed the asset, in descending order (most-recently viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostViewedAssets
public static List<AssetViews> mostViewedAssets(int maxAssets, boolean byDifferentUsers) throws AtlanException Find the most-viewed assets in Atlan.- Parameters:
maxAssets
- maximum number of assets to considerbyDifferentUsers
- when true, will consider assets viewed by more users as more important than total view count, otherwise will consider total view count most important- Returns:
- the list of assets that are most-viewed, in descending order (most-viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostViewedAssets
public static List<AssetViews> mostViewedAssets(int maxAssets, boolean byDifferentUsers, List<String> excludeUsers) throws AtlanException Find the most-viewed assets in Atlan.- Parameters:
maxAssets
- maximum number of assets to considerbyDifferentUsers
- when true, will consider assets viewed by more users as more important than total view count, otherwise will consider total view count most importantexcludeUsers
- list of usernames to exclude from the results- Returns:
- the list of assets that are most-viewed, in descending order (most-viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostViewedAssets
public static List<AssetViews> mostViewedAssets(AtlanClient client, int maxAssets, boolean byDifferentUsers) throws AtlanException Find the most-viewed assets in Atlan.- Parameters:
client
- connectivity to the Atlan tenant on which to run the searchmaxAssets
- maximum number of assets to considerbyDifferentUsers
- when true, will consider assets viewed by more users as more important than total view count, otherwise will consider total view count most important- Returns:
- the list of assets that are most-viewed, in descending order (most-viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
mostViewedAssets
public static List<AssetViews> mostViewedAssets(AtlanClient client, int maxAssets, boolean byDifferentUsers, List<String> excludeUsers) throws AtlanException Find the most-viewed assets in Atlan.- Parameters:
client
- connectivity to the Atlan tenant on which to run the searchmaxAssets
- maximum number of assets to considerbyDifferentUsers
- when true, will consider assets viewed by more users as more important than total view count, otherwise will consider total view count most importantexcludeUsers
- list of usernames to exclude from the results- Returns:
- the list of assets that are most-viewed, in descending order (most-viewed first)
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
search
Run the search.- Returns:
- the matching assets
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
search
Run the search.- Parameters:
client
- connectivity to the Atlan tenant on which to run the search- Returns:
- the matching assets
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
count
Return the total number of search log entries that will match the supplied criteria, using the most minimal query possible (retrieves minimal data).- Returns:
- the count of search log entries that will match the supplied criteria
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
count
Return the total number of search log entries that will match the supplied criteria, using the most minimal query possible (retrieves minimal data).- Parameters:
client
- through which to run the request- Returns:
- the count of search log entries that will match the supplied criteria
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
stream
Run the search to retrieve entries that match the supplied criteria.- Returns:
- a stream of search log entries that match the specified criteria, lazily-fetched
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
stream
Run the search to retrieve entries that match the supplied criteria.- Parameters:
client
- through which to run the request- Returns:
- a stream of search log entries that match the specified criteria, lazily-fetched
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
stream
Run the search to retrieve entries that match the supplied criteria.- Parameters:
parallel
- if true, returns a parallel stream- Returns:
- a stream of search log entries that match the specified criteria, lazily-fetched
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
stream
Run the search to retrieve entries that match the supplied criteria.- Parameters:
client
- through which to run the requestparallel
- if true, returns a parallel stream- Returns:
- a stream of search log entries that match the specified criteria, lazily-fetched
- Throws:
AtlanException
- on any issues interacting with the Atlan APIs
-
_internal
-
toBuilder
-
getDsl
Parameters for the search itself. -
equals
- Overrides:
equals
in classAtlanObject
-
canEqual
- Overrides:
canEqual
in classAtlanObject
-
hashCode
public int hashCode()- Overrides:
hashCode
in classAtlanObject
-
toString
Description copied from class:AtlanObject
- Overrides:
toString
in classAtlanObject
-