Digital Developer Conference: a FREE half-day online conference focused on AI & Cloud – North America: Nov 2 – India: Nov 9 – Europe: Nov 14 – Asia Nov 23 Register now

Close outline
  • United States
IBM?
  • Site map
IBM?
  • Marketplace

  • Close
    Search
  • Sign in
    • Sign in
    • Register
  • IBM Navigation
IBM Developer Answers
  • Spaces
    • Blockchain
    • IBM Cloud platform
    • Internet of Things
    • Predictive Analytics
    • Watson
    • See all spaces
  • Tags
  • Users
  • Badges
  • FAQ
  • Help
Close

Name

Community

  • Learn
  • Develop
  • Connect

Discover IBM

  • ConnectMarketplace
  • Products
  • Services
  • Industries
  • Careers
  • Partners
  • Support
10.190.13.195

Refine your search by using the following advanced search options.

Criteria Usage
Questions with keyword1 or keyword2 keyword1 keyword2
Questions with a mandatory word, e.g. keyword2 keyword1 +keyword2
Questions excluding a word, e.g. keyword2 keyword1 -keyword2
Questions with keyword(s) and a specific tag keyword1 [tag1]
Questions with keyword(s) and either of two or more specific tags keyword1 [tag1] [tag2]
To search for all posts by a user or all posts with a specific tag, start typing and choose from the suggestion list. Do not use a plus or minus sign with a tag, e.g., +[tag1].
  • Ask a question

R&R: Problem with Solr Managed resources

310000YRPW gravatar image
Question by JaviMartin  (1) | Nov 24, 2015 at 05:19 AM watsonretrieve-and-ranksolr

We have to change the list of synonyms and empty words used by the service of R & R. We do not want to load all the documents after each addition of synonyms or empty words , so we decided to use ManagedResources Solr . But by invoking the url to add a word ('palabra') to the stopwords we found a problem. We obtain different values of the list of managed stopwords (stopwords_man_es) in two consecutive invocations:

$ curl -u "{username}":"{password}" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc9bdf1dcf_741f_4074_81d1_2bbbee938778/solr/comex-collection/schema/analysis/stopwords/stopwords_man_es"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 237 0 237 0 0 205 0 --:--:-- 0:00:01 --:--:-- 211{ "responseHeader":{ "status":0, "QTime":1}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-11-23T10:30:54.006Z", "updatedSinceInit":"2015-11-23T10:38:21.533Z", "managedList":["palabra"]}}

$ curl -u "{username}":"{password}" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc9bdf1dcf_741f_4074_81d1_2bbbee938778/solr/comex-collection/schema/analysis/stopwords/stopwords_man_es"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 176 0 176 0 0 152 0 --:--:-- 0:00:01 --:--:-- 154{ "responseHeader":{ "status":0, "QTime":2}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-11-23T10:30:00.33Z", "managedList":[]}}

Retrive and rank support solr managed resources api ?

People who like this

  0
Comment
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster

2 answers

  • Sort: 
270005QU2K gravatar image

Answer by lindner.scott (1111) | Nov 30, 2015 at 02:30 PM

Hi - we're currently looking into this issue and we believe we will need to open up an API that we currently block so that you can force a "reload" on your collections. See the "applying changes" section of https://cwiki.apache.org/confluence/display/solr/Managed+Resources

Until that is done you can't guarantee that all cores / replicas have the same information - but given that we currently block that call it means for the time being this can't reliably work. (FYI we're looking to allow this API call very shortly for this specific reason).

As for what you're seeing with two successive calls giving different results - can you add more details around how you got into this state? Do you have something scripted to create a collection and quickly add a synonym perhaps?

Thanks,

-Scott

Comment

People who like this

  0   Share
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
310000YRPW gravatar image

Answer by JaviMartin (1) | Dec 14, 2015 at 11:05 AM

Thanks for the answer! I create a collection and i add stopwords.... but no 'quickly'. No script, manual invocation using curl only for testing reasons.

Steps after load configuration (with managedstopword list in queryanalizer) ...

1) create collection:

default@S4RCD11 ~ $ curl -X POST -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/admin/collections" -d "action=CREATE&name=comex-collection&collection.configName=caixabank-config"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 556 0 482 100 74 135 20 0:00:03 0:00:03 --:--:-- 136

0231001718comex-collection_shard1_replica202131comex-collection_shard1_replica1

2) List managed stopword list "spanish" (no words, correct):

default@S4RCD11 ~ $ curl -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 179 0 179 0 0 143 0 --:--:-- 0:00:01 --:--:-- 145{ "responseHeader":{ "status":0, "QTime":144}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-12-14T10:06:11.087Z", "managedList":[]}}

3) Add word "palabra" to managed stopword list "spanish" (status 0 - no error, correct):

default@S4RCD11 ~ $ curl -X POST -H "Content-Type: application/json" -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish" --data-binary '["palabra"]'

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 66 0 55 100 11 51 10 0:00:01 0:00:01 --:--:-- 51{ "responseHeader":{ "status":0, "QTime":9}}

4) List managed stopword list "spanish" (no words, INCORRECT):

default@S4RCD11 ~ $ curl -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 179 0 179 0 0 147 0 --:--:-- 0:00:01 --:--:-- 151{ "responseHeader":{ "status":0, "QTime":116}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-12-14T10:06:11.112Z", "managedList":[]}}

5) List managed stopword list "spanish" RETRY (no words, INCORRECT):

default@S4RCD11 ~ $ curl -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 177 0 177 0 0 162 0 --:--:-- 0:00:01 --:--:-- 164{ "responseHeader":{ "status":0, "QTime":1}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-12-14T10:06:11.112Z", "managedList":[]}}

6) List managed stopword list "spanish" RETRY (1 word, CORRECT):

default@S4RCD11 ~ $ curl -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 237 0 237 0 0 220 0 --:--:-- 0:00:01 --:--:-- 223{ "responseHeader":{ "status":0, "QTime":1}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-12-14T10:06:11.087Z", "updatedSinceInit":"2015-12-14T10:07:30.833Z", "managedList":["palabra"]}}

7) List managed stopword list "spanish" RETRY (no words, INCORRECT):

default@S4RCD11 ~ $ curl -u "e7f5aa8d-bbcb-4ac5-8bc4-ea883e7713f0":"ljEjZJH63AHy" "https://gateway.watsonplatform.net/retrieve-and-rank/api/v1/solr_clusters/sc48f94378_fd0a_4606_911e_8d71b56e98f9/solr/comex-collection/schema/analysis/stopwords/spanish"

Response:

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 177 0 177 0 0 166 0 --:--:-- 0:00:01 --:--:-- 169{ "responseHeader":{ "status":0, "QTime":1}, "wordSet":{ "initArgs":{"ignoreCase":false}, "initializedOn":"2015-12-14T10:06:11.112Z", "managedList":[]}}

Comment

People who like this

  0   Share
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster

Follow this question

56 people are following this question.

Answers

Answers & comments

Related questions

Field type = watson_text_en or watson_text? 2 Answers

Re-index documents after some changes 0 Answers

How to change a configuration set (for instance the schema)? 2 Answers

Rank & Retrieve, cannot access service. 3 Answers

Creating Retrieve&Rank configuration in Python: zip file error 1 Answer

  • Contact
  • Privacy
  • IBM Developer Terms of use
  • Accessibility
  • Report Abuse
  • Cookie Preferences

Powered by AnswerHub

Authentication check. Please ignore.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • API Connect
  • Analytic Hybrid Cloud Core
  • Application Performance Management
  • Appsecdev
  • BPM
  • Blockchain
  • Business Transaction Intelligence
  • CAPI
  • CAPI SNAP
  • CICS
  • Cloud Analytics
  • Cloud Automation
  • Cloud Object Storage
  • Cloud marketplace
  • Collaboration
  • Content Services (ECM)
  • Continuous Testing
  • Courses
  • Customer Experience Analytics
  • DB2 LUW
  • Data and AI
  • DataPower
  • Decision Optimization
  • DevOps Build
  • DevOps Services
  • Developers IBM MX
  • Digital Commerce
  • Digital Experience
  • Finance
  • Global Entrepreneur Program
  • Hadoop
  • Hybrid Cloud Core
  • Hyper Protect
  • IBM Cloud platform
  • IBM Design
  • IBM Forms Experience Builder
  • IBM Maximo Developer
  • IBM StoredIQ
  • IBM StoredIQ-Cartridges
  • IIDR
  • ITOA
  • InformationServer
  • Integration Bus
  • Internet of Things
  • Kenexa
  • Linux on Power
  • LinuxONE
  • MDM
  • Mainframe
  • Messaging
  • Node.js
  • ODM
  • Open
  • PartnerWorld Developer Support
  • PowerAI
  • PowerVC
  • Predictive Analytics
  • Product Insights
  • PureData for Analytics
  • Push
  • QRadar App Development
  • Run Book Automation
  • Search Insights
  • Security Core
  • Storage
  • Storage Core
  • Streamsdev
  • Supply Chain Business Network
  • Supply Chain Insights
  • Swift
  • UBX Capture
  • Universal Behavior Exchange
  • UrbanCode
  • WASdev
  • WSRR
  • Watson
  • Watson Campaign Automation
  • Watson Content Hub
  • Watson Marketing Insights
  • dW Answers Help
  • dW Premium
  • developerWorks Sandbox
  • developerWorks Team
  • Watson Health
  • More
  • Tags
  • Questions
  • Users
  • Badges