Comments (3)
Could be done like this:
public void appendMessage(final String jobId, final JobMessage jobMessage) {
if (jobMessage.getLevel() == Level.ERROR) {
writeMessageAndStatus(jobId, jobMessage.getLevel(), jobMessage.getMessage(), ERROR, jobMessage.getTimestamp());
} else {
writeMessageAndStatus(jobId, jobMessage.getLevel(), jobMessage.getMessage(), null, jobMessage.getTimestamp());
}
}
private void writeMessageAndStatus(final String jobId, final Level messageLevel, final String message, final JobStatus jobStatus,
final OffsetDateTime timestamp) {
// TODO: Refactor JobRepository so only a single update is required
jobRepository.appendMessage(jobId, jobMessage(messageLevel, message, timestamp));
if (jobStatus != null) {
jobRepository.setJobStatus(jobId, jobStatus);
}
}
Sorry for not doing a pull request myself - but I cant find the time now :(
from edison-microservice.
Thanks for finding this, we fixed it.
from edison-microservice.
No problem :) Thank you!
from edison-microservice.
Related Issues (20)
- edison-validation missing a lot of Validation Exceptions in Controller Advice
- the spring boot actuator trace endpoint changed to httptrace
- ldap Authentication Problems with Edison 2.0.0-rc3
- Reimplement JobEventPublisher for Backwards Compatibility HOT 1
- status details indicator for long running jobs in edison jobs
- use OpenJDK instead of OracleJDK in TravisCI Builds HOT 1
- [edison-jobs] Limit number of preserved log entries HOT 1
- [edison-mongo] AbstractMongoRepository.size() is unsuitable for big collections HOT 1
- [edison-core] support parameter-names that have slashes to create structures
- TogglzConfiguration.userProvider() - Admin is always true
- ArithmethicException when JobInfo contains no messages HOT 2
- Add project metadata to META-INF/MANIFEST.MF
- TestFeatureManager enableAll disables all features HOT 3
- s3TogglzConfig and mongoTogglzConfig can exist at the same time
- [edison-jobs] Inconsistencies in job locks
- Provide support for MongoDB ConnectionString HOT 1
- Don't use document arrays for MongoDB job log messages
- JobMarker wird in JobMessageLogAppender nicht mehr korrekt ausgewertet HOT 1
- Refactor de.otto.edison.metrics to use micrometer.io instead of Dropwizard metrics. 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 edison-microservice.