Enum Class Athena2OutputType
- All Implemented Interfaces:
Serializable
,Comparable<Athena2OutputType>
,Constable
Represents various ways to return query results from Athena. For example, choose between a streaming iterator that
will eventually yield all results, a static list of rows and next token, or a pointer to the results in S3.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionReturn the path to the results in S3.Return a static list of rows.When using an endpoint that returns rows directly back to the caller, such asgetQueryResults
, use AWS 2 AthenaGetQueryResultsIterable
to return a streaming list of results. -
Method Summary
Modifier and TypeMethodDescriptionstatic Athena2OutputType
Returns the enum constant of this class with the specified name.static Athena2OutputType[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
StreamList
When using an endpoint that returns rows directly back to the caller, such asgetQueryResults
, use AWS 2 AthenaGetQueryResultsIterable
to return a streaming list of results. Returning a streaming result means that no API requests happen until the streaming result is accessed the first time.This is the type to use if you need to process large result sets in memory (as opposed to in another process like an EMR job), as the iterable returned using this method will stream results from AWS a page at a time, thus limiting the amount of memory consumed at any one point in time.
-
SelectList
Return a static list of rows. The amount of rows returned is limited to the max response size of Athena'sGetQueryResults
(currently 1,000). Will also set theAthena2Constants.NEXT_TOKEN
header to allow access to the next page of results.- See Also:
-
S3Pointer
Return the path to the results in S3. This may be preferred if you want to pass a pointer to the results to another process for handling.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-