Comments (6)
This should be autodetected when running in a Boxfuse instance here: https://github.com/boxfuse/cloudwatchlogs-java-appender/blob/master/src/main/java/com/boxfuse/cloudwatchlogs/internal/CloudwatchLogsLogEventPutter.java#L54
Do you find it making the wrong choice for you? If yes, how so?
from cloudwatchlogs-java-appender.
It works perfectly when running in AWS; and when running in local Boxfuse instance, I can easily fuse an environment variable, so it's not a problem as well. However, if running on a local machine, I have to not forget to set this variable in IDE's run configuration (or set an OS/user level environment variable) myself, and to explain this to all team members who're working with logging. It wasn't a problem until we started migrating all our codebase to use Markers and MDC to get better structured logs - having a way to just set it to a correct AWS region in log4j2.xml
(which would then be shared with all team members) would've been nice.
If you're against exposing this config option, that's fine by me; if not - let me implement that (early next week seems likely) and send you a PR.
from cloudwatchlogs-java-appender.
Note that there is no need to set anything in a local Boxfuse instance as Boxfuse will automatically override the endpoint to point to a local CloudWatch Logs mock that is started by the Boxfuse Client. See https://github.com/boxfuse/cloudwatchlogs-java-appender/blob/master/src/main/java/com/boxfuse/cloudwatchlogs/CloudwatchLogsConfig.java#L21
Currently the appender auto-disables itself outside of a Boxfuse instance (due to the lack of AWS_REGION
and "BOXFUSE_CLOUDWATCHLOGS_ENDPOINT
environment variables). I assume this is not the behavior you want. Do you instead want it to log to
- AWS CloudWatch Logs
- a local CloudWatch Logs mock
- stdout
?
from cloudwatchlogs-java-appender.
TBH, I'd like it to log to wherever I can see the whole logged event (to make sure that all the fields are set correctly).
from cloudwatchlogs-java-appender.
The new stdoutFallback
configuration property now enables outputting events to stdout in case no AWS region was detected.
from cloudwatchlogs-java-appender.
Works very well, thanks a lot!
from cloudwatchlogs-java-appender.
Related Issues (11)
- Enforce that all events within a single PutLogEvents call are always chronological
- Issue with dropping off/losing logs when pushing to cloudwatch at the end of program execution HOT 3
- Configure Custom MDC Fields HOT 1
- Log Message Contains All Metadata HOT 4
- Do not let log thread die after an exception / auto-restart if possible HOT 1
- Publish to Maven Central
- Document minimum version requirements for logging libraries HOT 1
- Make log group configurable
- too high logging throughput makes our app unresponsive HOT 27
- Handle DataAlreadyAcceptedException
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 cloudwatchlogs-java-appender.