Coder Social home page Coder Social logo

Comments (8)

ReneKroon avatar ReneKroon commented on May 20, 2024 1

@zkynet Can you test this code? Its merged to master but not an official release yet.

from ttlcache.

zveinn avatar zveinn commented on May 20, 2024 1

Completely forgot to report back!

It seems that did it. Thanks man!

from ttlcache.

ReneKroon avatar ReneKroon commented on May 20, 2024

Good call, i'll fix it in the upcoming 2 weeks i think.

I guess adding a Close method would work?

from ttlcache.

zveinn avatar zveinn commented on May 20, 2024

Yep, that should do it!

However, maybe "close" is not the right description. Somehow close feels like a non-permanent move. Maybe it's just me ?

Since you already have:
NewChache()

Maybe one of these two:
DeleteCache()
RemoveCache()

from ttlcache.

zveinn avatar zveinn commented on May 20, 2024

Actually, now that I think about it. Do you feel like getting some help on the package ?

I would not mind implementing a fix for you. I can make some adjustments and then deliver them in PR's.

from ttlcache.

ReneKroon avatar ReneKroon commented on May 20, 2024

A pull request is always welcome. i think 'RemoveCache' is a good name but i also like to check if we can use some common standard interface. For example, Closer reads:

type Closer
Closer is the interface that wraps the basic Close method.

The behavior of Close after the first call is undefined. Specific implementations may document their own behavior.

type Closer interface {
    Close() error
}

But in this case i'm happy with either solution.

from ttlcache.

zveinn avatar zveinn commented on May 20, 2024

Yep, that makes perfect sense. I will take a look this week and see if I can't get this done :)

from ttlcache.

zveinn avatar zveinn commented on May 20, 2024

Sweet, I was about to get my hand dirty tonight, but since you already did I'll do a testing session in stead. It'll happen in about 6-7 hours.

Good job.

from ttlcache.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.