Looking for a little guidance on upgrading to 0.11...
# all-things-deployment
n
Looking for a little guidance on upgrading to 0.11.0 using my Helm Kubernetes deployment. I have made the needed changes to the values.yaml file, and run the helm upgrade as I have in the past (in QA). I see the datahub-datahub-system-update-job come up and the logs looked like they were re-indexing. It took around 10 hours. This morning the job had succeeded but I still see version 0.10.5 in the UI. I did notice the Helm command had timed out because the update job took so long. Wondering if someone could explain what jobs need to run as a part of this upgrade. Also I didnt notice any actual downtime in the UI? **In QA I ran the HELM upgrade again and the job is re-indexing again... back at 1% looking like itll take another 10 hours. Not sure how Im going to make this work in PROD, or if ill be able to upgrade to the newest version.
@little-megabyte-1074 Wondering if you could point me to someone who might be able to explain the best approach here, sorry to tag you but running the upgrade has left our QA env in a bad state.
the system update is no perpetually failing with this error...
ERROR c.l.d.u.s.e.s.BuildIndicesPreStep:81 - BuildIndicesPreStep failed.
Copy code
{
  "error": {
    "root_cause": [
      {
        "type": "circuit_breaking_exception",
        "reason": "[parent] Data too large, data for [<http_request>] would be [384580272/366.7mb], which is larger than the limit of [382520524/364.7mb], real usage: [384580272/366.7mb], new bytes reserved: [0/0b], usages [request=425984/416kb, fielddata=9871/9.6kb, in_flight_requests=9813002/9.3mb, model_inference=0/0b, eql_sequence=0/0b, accounting=5934280/5.6mb]",
        "bytes_wanted": 384580272,
        "bytes_limit": 382520524,
        "durability": "TRANSIENT"
      }
    ],
    "type": "circuit_breaking_exception",
    "reason": "[parent] Data too large, data for [<http_request>] would be [384580272/366.7mb], which is larger than the limit of [382520524/364.7mb], real usage: [384580272/366.7mb], new bytes reserved: [0/0b], usages [request=425984/416kb, fielddata=9871/9.6kb, in_flight_requests=9813002/9.3mb, model_inference=0/0b, eql_sequence=0/0b, accounting=5934280/5.6mb]",
    "bytes_wanted": 384580272,
    "bytes_limit": 382520524,
    "durability": "TRANSIENT"
  },
  "status": 429
}
Continuing this... had to drop the volumes on ElasticSearch and then run the restore-indices job to get back... the job is estimated to take 68 hours.
a
Hello Drew, how many entities do you have in your catalog? Do you count the rows in the database or entities/size of indexes in ElasticSearch?
We also need to upgrade and would like to make an estimate on how long it will take for us.
n
not sure about the actual best way to pull that number but referencing the Analytics tab we have...
@gray-shoe-75895 Do you know if there is any proper docs and steps to follow to upgrade Datahub via helm, like which values need to be set to true, or which of any of the jobs should be manually triggered.
r
@brainy-tent-14503 - could you look into this?
n
When the restore-indices job starts it says there are 19,597,094 rows it needs to send MAE's for. Which seems like way too many. Im thinking we may have alot of DataPrcocessInstances coming from the airlfow package that are really clogging things up.
a
btw - you can set
capture_executions
to false if you want to stop getting dataProcessInstances in the future
thank you 1
✔️ 1
b
Nice, I didn’t know about that setting. A lot of instances accumulate these entities which because of their ids are probably better modeled as timeseries which allows for bypassing sql storage later and easier truncation in ES.
I believe the old entities can be deleted, but the delete process will be slow. Future work around better deletion of these in bulk is needed.
plus1 1
n
the delete process is very slow, I am running a daily job to clean them up as we do actually want a days worth of runs in Datahub for users to check
@brainy-tent-14503 My team is looking into setting a Retention Policy for all aspects and entities, but having a very hard time following this doc, especially in regards to this PR and the comments that seem to contradict it. Would really appreciate any insight. Upgrading to 0.11.0 has been blocked for weeks as we have too many aspects/entities accumulated. https://github.com/datahub-project/datahub/pull/7295 https://datahubproject.io/docs/0.10.5/advanced/db-retention
b
To be clear the retention policy is for retaining historical versions of entities. Only the latest version is indexed in ES and thus the restore indices is only operating on version 0 or the latest version. The retention applies to the historical versions which are only stored in SQL. Setting a retention policy doesn’t change the number of entities, merely the number of previous versions of them. Does that make sense?
🫡 1
n
@brainy-tent-14503 Yes that does make sense, thank you. We just pulled the MYSQL query to break down our aspect count and see this at the top. The Restore-indices job says there are 17million aspects in the table that it needs to re-hydrate from, which makes sense looking at this. Based on your point about the versions only being stored in SQL, are these 17million pure (version 0) aspects? **edit: we confirmed this is filtered to version = 0*** Or are many of them old versions that wont be rehydrated. The root issue is the restore-indices and re-index jobs are taking far too long.
Copy code
+----------------------------------+--------------+
| aspect                           | aspect_count |
+----------------------------------+--------------+
| dataProcessInstanceProperties    |      3534964 |
| dataProcessInstanceRelationships |      3526886 |
| dataProcessInstanceKey           |      3526866 |
| dataProcessInstanceOutput        |      3244680 |
| dataProcessInstanceInput         |      2780390 |
| datasetProperties                |        96470 |
| dataJobInfo                      |        56675 |
| dataJobInputOutput               |        54784 |
| browsePaths                      |        37825 |
| browsePathsV2                    |        36718 |
| dataPlatformInstance             |        36430 |
| status                           |        35665 |
| upstreamLineage                  |        29418 |
| schemaMetadata                   |        28851 |
| datasetKey                       |        24744 |
| subTypes                         |        21116 |
| domains                          |        16942 |
| container                        |        16941 |
| viewProperties                   |        12675 |
| ownership                        |        12511 |
| globalTags                       |        11960 |
| dataJobKey                       |         8158 |
| dataHubExecutionRequestInput     |         4332 |
| dataHubExecutionRequestResult    |         4293 |
| dataHubExecutionRequestKey       |         4000 |
| siblings                         |         2222 |
| dataHubStepStateProperties       |          187 |
| dataHubStepStateKey              |          177 |
| dataFlowInfo                     |          148 |
| dataFlowKey                      |          102 |
| containerProperties              |           66 |
I have taken a crack at a few different threaded python scripts to delete dataProcessInstances (hard) efficiently, but considering that the
graph.get_urns_by_filter
returns a scrollAcrossEntities error, as well as it takes hours and hours to cleanup this hasnt been super effective.
We are essentially running a daily DAG to cleanup dataProcessInstances more than a day old, and that itself is a pretty hefty process. While deleting stuff like Dataset Operation aspect is super fast and easy. whats concerning me is that this list of counts is after we deleted the DataProcesssInstance by URN, but the aspects remain?
a
Check to see if you’re executing a
soft
delete vs
hard
delete. A soft delete will set a
status
aspect instead of actually removing them. In that case however I’d expect to see a larger number of
status
aspects though, but it depends on how many possible
soft
deletes were executed so far.
n
They are all hard deletes...
graph.delete_entity(data_process_instance_urn, hard=True)
s
@numerous-address-22061 @brainy-tent-14503 how did you get around the
Copy code
"Caused by: org.elasticsearch.common.breaker.CircuitBreakingException: [parent] Data too large, data for [internal:cluster/shard/started] would be [514275828/490.4mb], which is larger than the limit of [510027366/486.3mb], real usage: [514275536/490.4mb], new bytes reserved: [292/292b], usages [request=0/0b, fielddata=2570/2.5kb, in_flight_requests=292/292b, model_inference=0/0b, eql_sequence=0/0b, accounting=4408152/4.2mb]"
error you were seeing a few months back? This is currently effecting our production cluster and have increased memory limits and still has not helped
b
Increase memory to your elasticsearch instance, looks like it only has maybe 512mb
s
I think 512 was the jvm heap limit