[
https://issues.apache.org/jira/browse/GOBBLIN-1518?focusedWorklogId=638921&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-638921
]
ASF GitHub Bot logged work on GOBBLIN-1518:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 17/Aug/21 23:34
Start Date: 17/Aug/21 23:34
Worklog Time Spent: 10m
Work Description: phet commented on a change in pull request #3367:
URL: https://github.com/apache/gobblin/pull/3367#discussion_r690792043
##########
File path:
gobblin-runtime/src/main/java/org/apache/gobblin/runtime/api/InstrumentedSpecStore.java
##########
@@ -164,13 +164,26 @@ public Spec updateSpec(Spec spec) throws IOException,
SpecNotFoundException {
}
}
+ @Override
+ public int getSize() throws IOException {
+ if (!instrumentationEnabled) {
+ return getSizeImpl();
+ } else {
+ long startTimeMillis = System.currentTimeMillis();
+ int size = getSizeImpl();
+ Instrumented.updateTimer(this.getAllTimer, System.currentTimeMillis() -
startTimeMillis, TimeUnit.MILLISECONDS);
Review comment:
looking at something else in this same file, I noticed this
(post-merge)...
wouldn't we want a separate `Timer`, to avoid mixing durations from two
different operations? I can include that change in what I'm working on now, if
you agree @arjun4084346
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 638921)
Time Spent: 1h 50m (was: 1h 40m)
> improve getting size of the spec store
> --------------------------------------
>
> Key: GOBBLIN-1518
> URL: https://issues.apache.org/jira/browse/GOBBLIN-1518
> Project: Apache Gobblin
> Issue Type: Improvement
> Reporter: Arjun Singh Bora
> Priority: Major
> Time Spent: 1h 50m
> Remaining Estimate: 0h
>
> right now there is no api to get size of the spec store.
> doing getAllSpecs and then calling size() over it, does a lot of unnecessary
> work
--
This message was sent by Atlassian Jira
(v8.3.4#803005)