<< Back to previous view

[CCACHE-53] Unnecessary get during SoftCache lookup Created: 29/Nov/18  Updated: 06/Jan/19  Resolved: 06/Jan/19

Status: Closed
Project: core.cache
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Enhancement Priority: Minor
Reporter: Neil Prosser Assignee: Sean Corfield
Resolution: Completed Votes: 1
Labels: performance

Attachments: Text File Remove-unnecessary-get.patch    
Patch: Code


Currently during a lookup (without default value) on the SoftCache we'll use the result of (.get r) for the ::nil-check and then get it again as we're about to return it. It's possible this could result in inconsistency but it's also an unnecessary call.

I've provided a patch which reuses the result of the get for the check and return value.

Comment by Sean Corfield [ 29/Nov/18 12:20 PM ]

Thanks Neil. I'll look at this (and CCACHE-52) when I get back from Conj. I don't see you listed here https://clojure.org/community/contributors – have you signed the Contributor's Agreement? (site updates tend to lag behind a bit).

Comment by Neil Prosser [ 29/Nov/18 2:47 PM ]

Thanks for that. Yes. I filled it out just before I created CCACHE-52 this morning. However, it didn't ask me for my name. I filled in all the fields and it said 'Complete' after I signed it. Happy to try again if my name doesn't appear in the list!

Comment by Sean Corfield [ 29/Nov/18 7:16 PM ]

No problem. The list is updated manually and folks are tied up with Conj this week. I'll try to ping Alex while I'm here and confirm your CA is on file.

Comment by Neil Prosser [ 19/Dec/18 7:38 AM ]

I've signed the agreement again just to make sure. Still not seeing anything on the contributors page. Is there a problem with the updating process?

Comment by Sean Corfield [ 19/Dec/18 1:26 PM ]

I've pinged Alex again. I gather the site publishing process just broke due to some infrastructure changes so things are more manual than usual. Thanks for the reminder!

Comment by Sean Corfield [ 19/Dec/18 3:05 PM ]

They have not received your signed agreement. There's an email verification step – did you get the email? Did you click on the verification link? Without that step, the process isn't complete.

Comment by Neil Prosser [ 20/Dec/18 2:14 AM ]

My apologies. It turns out that running through the process twice wasn't enough for me to spot the 'Click here to sign' button hidden under the cookie warning (which I now find I ignore across all sites).

I have had the email confirmation and it all looks like it has gone through.

Comment by Sean Corfield [ 20/Dec/18 8:02 PM ]

Alex confirmed receipt of your CLA. Thank you! I'll probably take a look at these issues over the holiday break some time.

Comment by Sean Corfield [ 06/Jan/19 4:33 PM ]

Will be in 0.7.2

Generated at Sun Apr 21 13:21:24 CDT 2019 using JIRA 4.4#649-r158309.