implydata / druid-client Goto Github PK
View Code? Open in Web Editor NEWJava client for http://druid.io/
License: Apache License 2.0
Java client for http://druid.io/
License: Apache License 2.0
master branch
line 150,line 182 miss param scheme.
druid 0.11.0 create DirectDruidClient need scheme param.
There are three compile errors:
JsonConfigProvider.bindInstance(binder, Key.get(DruidNode.class, Self.class),
new DruidNode("druid-client", null, null));
final DirectDruidClient directDruidClient = new DirectDruidClient(WAREHOUSE, WATCHER, SMILE_MAPPER, httpClient,
host, SERVICE_EMITTER);
final DirectDruidClient directDruidClient = new DirectDruidClient(WAREHOUSE, WATCHER, SMILE_MAPPER, httpClient,
host, SERVICE_EMITTER);
Please review it!
(Thank for great project)
Hi
I am running the example class "ExampleMain" updated for my environment. The query seems to be running ok, but I get an error when retrieving the results. Below log and stack trace, the first line of the stack trace is
final List<Result<SelectResultValue>> resultList = Sequences.toList(resultSequence, Lists.<Result<SelectResultValue>>newArrayList());
Thank You
2017-09-21T09:21:27,241 INFO [main] org.hibernate.validator.internal.util.Version - HV000001: Hibernate Validator 5.1.3.Final
2017-09-21 09:21:27 INFO JsonConfigurator:70 - Loaded class[class io.druid.guice.ExtensionsConfig] from props[druid.extensions.] as [ExtensionsConfig{searchCurrentClassloader=true, directory='extensions', hadoopDependenciesDir='hadoop-dependencies', hadoopContainerDruidClasspath='null', loadList=null}]
2017-09-21 09:21:27 WARN Log4jShutterDownerModule:83 - Shutdown callback registry expected class [io.druid.common.config.Log4jShutdown] found [org.apache.logging.log4j.core.util.DefaultShutdownCallbackRegistry]. Skipping shutdown registry
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.server.metrics.DruidMonitorSchedulerConfig] from props[druid.monitoring.] as [io.druid.server.metrics.DruidMonitorSchedulerConfig@5e76a2bb]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.server.metrics.MonitorsConfig] from props[druid.monitoring.] as [MonitorsConfig{monitors=[]}]
2017-09-21 09:21:28 INFO MetricsModule:70 - Adding monitor[io.druid.query.ExecutorServiceMonitor@464a4442]
2017-09-21 09:21:28 INFO MetricsModule:70 - Adding monitor[io.druid.server.initialization.jetty.JettyServerModule$JettyMonitor@5c41d037]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.query.search.search.SearchQueryConfig] from props[druid.query.search.] as [io.druid.query.search.search.SearchQueryConfig@585c13de]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.query.metadata.SegmentMetadataQueryConfig] from props[druid.query.segmentMetadata.] as [io.druid.query.metadata.SegmentMetadataQueryConfig@5395ea39]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.query.groupby.GroupByQueryConfig] from props[druid.query.groupBy.] as [io.druid.query.groupby.GroupByQueryConfig@6a714237]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.query.topn.TopNQueryConfig] from props[druid.query.topN.] as [io.druid.query.topn.TopNQueryConfig@5cbb84b1]
2017-09-21 09:21:28 INFO JsonConfigurator:70 - Loaded class[class io.druid.guice.http.DruidHttpClientConfig] from props[druid.client.http.] as [io.druid.guice.http.DruidHttpClientConfig@773bd77b]
2017-09-21 09:21:28 DEBUG DruidClient:56 - Issuing query: {"queryType":"select","dataSource":{"type":"table","name":"damneat"},"intervals":{"type":"LegacySegmentSpec","intervals":["2000-01-01T00:00:00.000+01:00/2000-01-02T00:00:00.000+01:00"]},"descending":false,"filter":null,"granularity":{"type":"all"},"dimensions":[{"type":"default","dimension":"ndg_id","outputName":"ndg_id"},{"type":"default","dimension":"debtor_type","outputName":"debtor_type"},{"type":"default","dimension":"debtor_name","outputName":"debtor_name"},{"type":"default","dimension":"contract_id","outputName":"contract_id"},{"type":"default","dimension":"warranty_id","outputName":"warranty_id"},{"type":"default","dimension":"warranty_de","outputName":"warranty_de"},{"type":"default","dimension":"appraisal_id","outputName":"appraisal_id"},{"type":"default","dimension":"goods_id","outputName":"goods_id"}],"metrics":[],"pagingSpec":{"pagingIdentifiers":{},"threshold":50,"fromNext":false},"context":null}
2017-09-21 09:21:28 DEBUG DirectDruidClient:56 - Querying queryId[null] url[http://localhost:18082/druid/v2/]
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] starting
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 INFO ChannelResourceFactory:70 - Generating: http://localhost:18082
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] messageReceived: DefaultHttpResponse(chunked: true)
HTTP/1.1 200 OK
Date: Thu, 21 Sep 2017 07:21:28 GMT
Content-Type: application/x-jackson-smile
X-Druid-Query-Id: 867c6f76-8770-48ce-95d7-5f483e6ef95b
X-Druid-Response-Context: {}
Vary: Accept-Encoding, User-Agent
Transfer-Encoding: chunked
Server: Jetty(9.3.19.v20170502)
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] Got response: 200 OK
2017-09-21 09:21:28 DEBUG DirectDruidClient:56 - Initial response from url[http://localhost:18082/druid/v2/] for queryId[null]
2017-09-21 09:21:28 INFO Lifecycle$AnnotationBasedHandler:70 - Invoking stop method[public void com.metamx.http.client.NettyHttpClient.stop()] on object[com.metamx.http.client.NettyHttpClient@21a66d45].
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] messageReceived: org.jboss.netty.handler.codec.http.DefaultHttpChunk@2ab36f76
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] Got chunk: 21222B, last=false
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] messageReceived: org.jboss.netty.handler.codec.http.HttpChunk$1@6870ab0
2017-09-21 09:21:28 DEBUG NettyHttpClient:56 - [POST http://localhost:18082/druid/v2/] Got chunk: 0B, last=true
2017-09-21 09:21:28 DEBUG DirectDruidClient:56 - Completed queryId[null] request to url[http://localhost:18082/druid/v2/] with 21,222 bytes returned in 20 millis [10,611,000.000000 b/s].
2017-09-21 09:21:28 INFO ResourcePool:70 - giveBack called after being closed. key[http://localhost:18082]
Exception in thread "main" java.lang.NoSuchFieldError: _rootByteSymbols
at com.fasterxml.jackson.dataformat.smile.SmileFactory._createParser(SmileFactory.java:369)
at com.fasterxml.jackson.dataformat.smile.SmileFactory.createParser(SmileFactory.java:299)
at com.fasterxml.jackson.dataformat.smile.SmileFactory.createParser(SmileFactory.java:27)
at io.druid.client.DirectDruidClient$JsonParserIterator.init(DirectDruidClient.java:479)
at io.druid.client.DirectDruidClient$JsonParserIterator.hasNext(DirectDruidClient.java:442)
at com.metamx.common.guava.BaseSequence.makeYielder(BaseSequence.java:103)
at com.metamx.common.guava.BaseSequence.toYielder(BaseSequence.java:81)
at com.metamx.common.guava.BaseSequence.accumulate(BaseSequence.java:67)
at com.metamx.common.guava.MappedSequence.accumulate(MappedSequence.java:40)
at com.metamx.common.guava.Sequences.toList(Sequences.java:113)
at ExampleMain.main(ExampleMain.java:55)
Hi, TopNQuery can't return PostAggregator's result, it only returns aggregator's result! is it a bug?
Hi,
I'm actually interested using this client in a project of mine. It appears like the artifact is not in Maven central Search results. Is this something that was just forgotten to be done?
I can also just probably copy/paste the client code into my project as well, but I guess I'm wondering more about what the state of this client is?
Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.