The JedisPooled class (part of the UnifiedJedis family introduced in Jedis 4 and continued in Jedis 5) provides a high-level, thread-safe abstraction over a connection pool. However, it does not directly expose the time() method, as this is considered a server-administration command rather than a data operation.
To call the TIME command using JedisPooled, you should use the eval() method to execute a small Lua script. This is the standard "escape hatch" for running commands that are not directly exposed by the wrapper.
Here is how you can do it:
Missing Method: The UnifiedJedis interface (which JedisPooled implements) unifies commands across standalone, cluster, and sharded modes. Since TIME returns a specific server's time, it is ambiguous in a cluster/sharded context (which node's time do you want?), so it is often omitted from the unified interface.
Thread Safety: The eval method is thread-safe and handles the connection pool management automatically, just like set or get.