Best Practices: Getting the Most Out of Neptune
The following are some general recommendations for working with Amazon Neptune. Use this information as a reference to quickly find recommendations for using Amazon Neptune and maximizing performance.
Contents
- Amazon Neptune Basic Operational Guidelines
- Amazon Neptune Security Best Practices
- Limit the Number of Distinct Predicates You Use
- Avoid long-running transactions where possible
- Best Practices for Using Neptune Metrics
- Best Practices for Tuning Neptune Queries
- Load Balancing Across Read Replicas
- Loading Faster Using a Temporary Larger Instance
- Resize your writer instance by failing over to a read-replica
- Avoid different instance classes in a cluster
- Retry Upload after Data Prefetch Task Interrupted Error
- General Best Practices for Using Gremlin with Neptune
- Best Practices Using the Gremlin Java Client with Neptune
- Use the Latest Version of the Gremlin Java Client
- Re-use the Client Object Across Multiple Threads
- Create Separate Gremlin Java Client Objects for Read and Write Endpoints
- Add Multiple Read Replica Endpoints to a Gremlin Java Connection Pool
- Close the Client to Avoid the Connections Limit
- Create a New Connection After Failover
- Set maxInProcess and maxSimultaneousUsage to the Same Value
- Send Queries to the Server as Bytecode Rather Than as Strings
- Always Completely Consume the ResultSet or Iterator Returned by a Query
- Bulk Add Vertices and Edges in Batches
- Disable DNS caching in the Java Virtual Machine
- Optionally, Set Timeouts at a Per-Query Level
- Use the Graphbinary Serialization Protocol
- Work Around a Keep-Alive Bug in Clients Earlier than 3.3.4
- Troubleshoot Gremlin Java client exceptions
- Neptune Best Practices Using SPARQL