Comments (4)
@elfring I'm generally a fan of smart pointers as raw pointers can become hard to manage. In this case, however I refrained from wrapping for a couple of reasons:
- Parts of Typesense initially began as a C project, and still uses some C-style code so those parts just used raw pointers.
- To a lesser extent, I was worried about the performance overhead introduced (admittedly this is more of a case for
shared_ptr
thanunique_ptr
) in hot loops. I did do some initial benchmarks where I saw some serious degradation.
In the end, instead of adopting a mixed style, just ended up not using it anywhere. To detect and prevent leaks, we have an integration test suite (which is not part of this repo) that's run under Valgrind.
from typesense.
How do you think about to improve the implementation of the member function “array::remove_index” (for example)?
from typesense.
@elfring I'm sorry for going silent on this thread. We're comfortable with using raw pointers as of today, given the heavy interoperability with the C libraries we're using. We might relook this at future. Thanks for bringing this up though!
from typesense.
The interoperability concerns do not matter for affected C++ classes.
Under which circumstances will you start to care for exception safety?
from typesense.
Related Issues (20)
- while creating Conversation Model with openAI getting error HOT 4
- Docs to install a specific version of typesense HOT 1
- facet_by's total_values is returning max_facet_value params value or default value when not present in params HOT 1
- Collection metadata not returned by /collections or /collections/<name>
- [Feature Request] Support updating metadata of a collection
- [Feature Request] Ability to integrate results from custom Semantic Search server e.g. ColbertV2 or RAGatouille
- Surprising behavior on ids containing URL-unsafe characters HOT 2
- Question: Is it possible to disable peering and run in standalone mode? HOT 1
- [Feature Request] Add support for faceting on joined reference fields HOT 1
- [Feature request] Support UPSERT by query
- geopoint doesn't accept the int as latitude and langitute
- [Feature Request] Filter Caching
- wrong facet_counts, missing facet values with Semantic Search
- Typesense uses host machine memory stats when running in Docker
- Memory Corruption in `fuzzy_search_fields`
- [Feature request] Add "cleanup" parameter to snapshot operation
- [BUG] Lazy filter performance issue when more than 10 terms in a filter_by field HOT 1
- Voice Query - Whisper
- why so many open file descriptors to the same file?
- cf/mistral/mistral-7b-instruct-v0.1 is only accepted Cloudflare Workers AI model
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from typesense.