Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DESCRIBE FORMATTED fails on Federated metastore tables #60

Closed
courtsVII opened this issue Apr 3, 2018 · 1 comment
Closed

DESCRIBE FORMATTED fails on Federated metastore tables #60

courtsVII opened this issue Apr 3, 2018 · 1 comment

Comments

@courtsVII
Copy link

courtsVII commented Apr 3, 2018

Hive command DESCRIBE FORMATTED failing:

2018-04-03T10:26:49,798 INFO  com.hotels.bdp.waggledance.client.ThriftMetastoreClient:158 - Opened a connection to metastore 'thrift://cloud9-lab-main.us-west-2.hcom-data-lab.aws.hcom:9083', total current connections to all metastores: 3
2018-04-03T10:26:49,798 INFO  com.hotels.bdp.waggledance.client.ThriftMetastoreClient:193 - Connected to metastore.
2018-04-03T10:26:49,802 DEBUG com.hotels.bdp.waggledance.mapping.service.impl.PrefixBasedDatabaseMappingService:173 - Database Name `bix_mobile` maps to metastore with EMPTY_PREFIX
2018-04-03T10:26:49,936 DEBUG com.hotels.bdp.waggledance.mapping.service.impl.PrefixBasedDatabaseMappingService:173 - Database Name `bix_mobile` maps to metastore with EMPTY_PREFIX
2018-04-03T10:26:50,014 DEBUG com.hotels.bdp.waggledance.server.FederatedHMSHandler:168 - #get_foreign_keys('ForeignKeysRequest(parent_db_name:null, parent_tb..54..l_apt_performancemanagement_endpoints_sort)'): thrown javax.validation.ConstraintViolationException(may not be null) out of com.jcabi.aspects.aj.MethodValidator#checkForViolations[189] in 45ms
2018-04-03T10:26:50,018 ERROR org.apache.hadoop.hive.metastore.RetryingHMSHandler:204 - javax.validation.ConstraintViolationException: may not be null
	at com.jcabi.aspects.aj.MethodValidator.checkForViolations(MethodValidator.java:189)
	at com.jcabi.aspects.aj.MethodValidator.validateMethod(MethodValidator.java:154)
	at com.jcabi.aspects.aj.MethodValidator.beforeMethod(MethodValidator.java:87)
	at com.hotels.bdp.waggledance.mapping.service.impl.MonitoredDatabaseMappingService.databaseMapping(MonitoredDatabaseMappingService.java:48)
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys_aroundBody566(FederatedHMSHandler.java:1384)
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler$AjcClosure567.run(FederatedHMSHandler.java:1)
	at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
	at com.hotels.bdp.waggledance.metrics.MonitoredAspect.monitor(MonitoredAspect.java:57)
	at com.hotels.bdp.waggledance.metrics.MonitoredAspect.monitor(MonitoredAspect.java:47)
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys_aroundBody568(FederatedHMSHandler.java:1382)
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler$AjcClosure569.run(FederatedHMSHandler.java:1)
	at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
	at com.jcabi.aspects.aj.MethodLogger.wrap(MethodLogger.java:213)
	at com.jcabi.aspects.aj.MethodLogger.ajc$inlineAccessMethod$com_jcabi_aspects_aj_MethodLogger$com_jcabi_aspects_aj_MethodLogger$wrap(MethodLogger.java:1)
	at com.jcabi.aspects.aj.MethodLogger.wrapMethod(MethodLogger.java:169)
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys(FederatedHMSHandler.java:1382)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at com.hotels.bdp.waggledance.server.ExceptionWrappingHMSHandler.invoke(ExceptionWrappingHMSHandler.java:50)
	at com.sun.proxy.$Proxy132.get_foreign_keys(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invokeInternal(RetryingHMSHandler.java:148)
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invoke(RetryingHMSHandler.java:107)
	at com.sun.proxy.$Proxy132.get_foreign_keys(Unknown Source)
	at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$get_foreign_keys.getResult(ThriftHiveMetastore.java:12933)
	at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$get_foreign_keys.getResult(ThriftHiveMetastore.java:12917)
	at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
	at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
	at org.apache.hadoop.hive.metastore.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:48)
	at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:286)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622)
	at java.lang.Thread.run(Thread.java:748)

2018-04-03T10:26:50,018 ERROR org.apache.thrift.server.TThreadPoolServer:297 - Error occurred during processing of message.
javax.validation.ConstraintViolationException: may not be null
	at com.jcabi.aspects.aj.MethodValidator.checkForViolations(MethodValidator.java:189) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.jcabi.aspects.aj.MethodValidator.validateMethod(MethodValidator.java:154) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.jcabi.aspects.aj.MethodValidator.beforeMethod(MethodValidator.java:87) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.hotels.bdp.waggledance.mapping.service.impl.MonitoredDatabaseMappingService.databaseMapping(MonitoredDatabaseMappingService.java:48) ~[classes!/:?]
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys_aroundBody566(FederatedHMSHandler.java:1384) ~[classes!/:?]
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler$AjcClosure567.run(FederatedHMSHandler.java:1) ~[classes!/:?]
	at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149) ~[aspectjweaver-1.8.10.jar!/:1.8.10]
	at com.hotels.bdp.waggledance.metrics.MonitoredAspect.monitor(MonitoredAspect.java:57) ~[classes!/:?]
	at com.hotels.bdp.waggledance.metrics.MonitoredAspect.monitor(MonitoredAspect.java:47) ~[classes!/:?]
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys_aroundBody568(FederatedHMSHandler.java:1382) ~[classes!/:?]
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler$AjcClosure569.run(FederatedHMSHandler.java:1) ~[classes!/:?]
	at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149) ~[aspectjweaver-1.8.10.jar!/:1.8.10]
	at com.jcabi.aspects.aj.MethodLogger.wrap(MethodLogger.java:213) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.jcabi.aspects.aj.MethodLogger.ajc$inlineAccessMethod$com_jcabi_aspects_aj_MethodLogger$com_jcabi_aspects_aj_MethodLogger$wrap(MethodLogger.java:1) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.jcabi.aspects.aj.MethodLogger.wrapMethod(MethodLogger.java:169) ~[jcabi-aspects-0.22.6.jar!/:?]
	at com.hotels.bdp.waggledance.server.FederatedHMSHandler.get_foreign_keys(FederatedHMSHandler.java:1382) ~[classes!/:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_171]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_171]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_171]
	at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_171]
	at com.hotels.bdp.waggledance.server.ExceptionWrappingHMSHandler.invoke(ExceptionWrappingHMSHandler.java:50) ~[classes!/:?]
	at com.sun.proxy.$Proxy132.get_foreign_keys(Unknown Source) ~[?:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_171]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_171]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_171]
	at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_171]
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invokeInternal(RetryingHMSHandler.java:148) ~[hive-metastore-2.3.0.jar!/:2.3.0]
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invoke(RetryingHMSHandler.java:107) ~[hive-metastore-2.3.0.jar!/:2.3.0]
	at com.sun.proxy.$Proxy132.get_foreign_keys(Unknown Source) ~[?:?]
	at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$get_foreign_keys.getResult(ThriftHiveMetastore.java:12933) ~[hive-metastore-2.3.0.jar!/:2.3.0]
	at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$get_foreign_keys.getResult(ThriftHiveMetastore.java:12917) ~[hive-metastore-2.3.0.jar!/:2.3.0]
	at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39) ~[libthrift-0.9.3.jar!/:0.9.3]
	at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39) ~[libthrift-0.9.3.jar!/:0.9.3]
	at org.apache.hadoop.hive.metastore.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:48) ~[hive-metastore-2.3.0.jar!/:2.3.0]
	at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:286) [libthrift-0.9.3.jar!/:0.9.3]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152) [?:1.7.0_171]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622) [?:1.7.0_171]
	at java.lang.Thread.run(Thread.java:748) [?:1.7.0_171]
2018-04-03T10:28:44,323 DEBUG com.hotels.bdp.waggledance.server.TTransportMonitor:66 - Releasing disconnected sessions
2018-04-03T10:28:44,326 INFO  com.hotels.bdp.waggledance.client.ThriftMetastoreClient:224 - Closed a connection to metastore, current connections: 2
2018-04-03T10:28:44,326 INFO  com.hotels.bdp.waggledance.client.ThriftMetastoreClient:224 - Closed a connection to metastore, current connections: 1
2018-04-03T10:28:44,327 INFO  com.hotels.bdp.waggledance.client.ThriftMetastoreClient:224 - Closed a connection to metastore, current connections: 0








2018-04-03T10:33:44,323 DEBUG com.hotels.bdp.waggledance.server.TTransportMonitor:66 - Releasing disconnected sessions

Describe Formatted failure occurs on the primary and the federated metastore tables:
Config

primary-meta-store:
  access-control-type: READ_ONLY
  database-prefix: ''
  name: primary
  remote-meta-store-uris: thrift://localhost:9083 
federated-meta-stores:
- access-control-type: READ_ONLY
  remote-meta-store-uris: thrift://localhost:9083   
  mapped-databases: []
  database-prefix: waggle_test_
  name: secondary

Output

hive> show databases;
OK
bdp
default
waggle_test_bdp
waggle_test_default
Time taken: 1.307 seconds, Fetched: 4 row(s)
hive> describe formatted bdp.test;
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. org.apache.thrift.transport.TTransportException
hive> describe formatted waggle_test_bdp.test;
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. org.apache.thrift.transport.TTransportException
hive> 
@teabot
Copy link
Contributor

teabot commented Apr 3, 2018

Perhaps we've missed a request/response database name mapping step for one or more of the metastore API functions used by this command?

@courtsVII courtsVII changed the title DESCRIBE FORMATTED fails DESCRIBE FORMATTED fails on Primary and Federated metastore tables Apr 3, 2018
@courtsVII courtsVII changed the title DESCRIBE FORMATTED fails on Primary and Federated metastore tables DESCRIBE FORMATTED fails on Federated metastore tables Apr 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants