I started trying to use the new search API, the demo is running smoothly, however there are some points that I am still confused about being an outsider in the search world.
First of all, how to create a document. Obviously, you cannot hardcode each line in the document, but what else can I do. Say, if I have a custom class (I use Java, but I think Python doesn't matter here), and I would add user information to the document and be able to do a full-text search on the address field.
class User {
String username;
String password;
String address;
}
In my data warehouse, I have this object with 10,000 instances, and if I need to create this document, I have to
Step 1: retrieve the instance of 10000 from the data warehouse
Step 2: Iterate through each user object and create 10,000 documents
Step 3: add all 10,000 documents to the index, and then I can search
Please correct me if the above three steps that I spoke about are incorrect.
If this is the case, does it make it that every time a new user is registered, we need to create a new document and add it to the index?