Comments (1)
Sure,
Bulk properties
The indexing to Elasticsearch are sent by bulk and not one by one.
So on each call to "log" it will be accumulated until we have enough messages to sent or until a timeout is reached.
BulkSize
Number of messages to save in the memory before sending to Elasticsearch.
Possible values:
Any number that is greater than 1
- normal behavior as described1
- Don't accumulate and just send each message0
- Rely only on timeout. Accumulate all messages until timeout is reached regardless the current number of messages.
BulkIdleTimeout
As described, once this timeout (in milliseconds) is reached the current messages that are waiting in the bulk will be sent to elastic even if BulkSize
isn't reached.
This action happens at a different thread than your code.
DropEventsOverBulkLimit
Sometimes users are ok with loosing some log messages in favor of memory and I/O.
You can set this property to True
in order to:
- Send messages to Elastic only when timeout is reached
- If a new message arrive and we already have
BulkSize
messages waiting - the message will be dropped and lost.
A warning message will be written to the log4net ErrorHandler (LogLog)
IndexAsync
Whether to send the requests to Elasticsearch in an async manner.
Technically it will use .net async/await for this.
If sets to True
each http request won't block your code and will call an async function that will send the request in different task.
If sets to False
each http request will block your code which called the log function until it's done.
Pay attention that if BulkSize
is greater than 1, not all calls to "log" will be blocked but only the last one that caused the bulk size to reach it's maximum size.
from log4stash.
Related Issues (20)
- Aliases for Index
- Using the template returns not data HOT 1
- Custom log4net values get submitted as { "Count": 1 } HOT 2
- Does not work with log4net 2.0.8 or higher HOT 5
- Unable to push logs to https elasticsearch from aspnet core HOT 3
- ConvertToArrayFilter: System.ArgumentNullException: Value cannot be null HOT 10
- log4stash v3.0.0 doesn't work with ElasticSearch 6.x HOT 1
- Log4Stash logging metadata info by itself HOT 2
- AWS Signature failure - Incorrect HOST header? HOT 1
- log4stash does not have Http compression for ES?
- Target Elasticsearch index is incorrect HOT 3
- Authentication configuration does not feel compatible with "log4net >= 2.0.8" HOT 2
- log4stach elastic search appender memory leak HOT 4
- Allowing self signed certs does not work (AllowSelfSignedServerCert) HOT 1
- Unobserved task exception in ASP.NET Web API project when using IndexAsync and BulkSize is reached during request
- In PrepareBulk: System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
- Can't set authentication method v3.0.4 HOT 4
- IndexOperationParams from example is not working HOT 1
- How to use it on .Net 6? HOT 1
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 log4stash.