Steven Jacobs created ASTERIXDB-2386:
----------------------------------------

             Summary: Metadata cache should be refreshed after a cluster 
restart.
                 Key: ASTERIXDB-2386
                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-2386
             Project: Apache AsterixDB
          Issue Type: Improvement
            Reporter: Steven Jacobs


After a cluster restart, queries that don't first call "use" on the dataverses 
involved will fail. This is because they aren't found in the metadata cache. 
The bug can be reproduced as follows:

drop dataverse channels if exists;
create dataverse channels;
use channels;

create type TweetMessageTypeuuid as closed {
 tweetid: uuid,
 sender_location: point,
 send_time: datetime,
 referred_topics: \{{ string }},
 message_text: string,
 countA: int32,
 countB: int32
};


create dataset TweetMessageuuids(TweetMessageTypeuuid)
primary key tweetid autogenerated;

create function NearbyTweetsContainingText(place, text) {
 (select m.message_text
 from TweetMessageuuids m
 where contains(m.message_text,text)
 and spatial_intersect(m.sender_location, place))
};

 

restart the cluster

Then try the following:

channels.NearbyTweetsContainingText("hello","world"); 

 

It works fine if you do this instead, because channels gets added to the cache:

use channels;
channels.NearbyTweetsContainingText("hello","world");

 

 

 

 

 

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to