Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
507 views
in Technique[技术] by (71.8m points)

elasticsearch - ElasticSearch-反规范化和数据冗余(ElasticSearch - denormalisation and data redundancy)

I have a question about ES data denormalization and data redundancy.

(我对ES数据非规范化和数据冗余有疑问。)

Let's say I want to use ES as a secondary data store for the web application.

(假设我想将ES用作Web应用程序的辅助数据存储。)

ES will be used as a search engine and changed data will be sent to ES by Kafka.

(ES将用作搜索引擎,并且更改的数据将由Kafka发送到ES。)

And the changes will be updated to DB.

(更改将更新到数据库。)

However what is not clear to me is denormalization of the data and also the best practice, which says that JOINs shouldn't be used since they are heavily impacting the performance of ES and since we need ES operating quickly as possible it is not a good move.

(但是,我不清楚数据的非正规化以及最佳实践,这是不应该使用JOIN的原因,因为它们会严重影响ES的性能,并且由于我们需要ES尽可能快地运行,因此这不是一个好方法。移动。)

So let us say that we would have - it is just a theoretical example... a Departments, each Department may have multiple Employees, and each Employee may be assigned to multiple Departments.

(因此,让我们说,我们将拥有-这只是一个理论示例...一个部门,每个部门可能有多个雇员,并且每个雇员可能被分配到多个部门。)

I have seen some best practice guide, which said that data should be stored either in the nested object or in the flat object structure.

(我看过一些最佳实践指南,该指南指出数据应存储在嵌套对象或平面对象结构中。)

So the question which arose in my head was that what if I changed, for example, the name of Employee.

(因此,我想到的问题是,如果我更改了雇员的姓名,该怎么办?)

Should I always change name of the Employee everywhere where he/she is - all departments, or is there any more smooth way to solve this issue?

(我应该在每个员工所在的地方(所有部门)始终更改员工的姓名,还是有解决此问题的更简便方法?)

Thank you very much in advance.

(提前非常感谢您。)

  ask by Miroslav B translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...