Repository navigation
Structured logging with optional JSON output - #3588
Conversation
| private SecurityCredentials checkSuccessfulState(SecurityCredentials sc) { | ||
| LOGGER.debug("AWS returned security credential : {} ", sc); | ||
| LOGGER.atDebug() | ||
| .addKeyValue("credential", sc::toString) |
There was a problem hiding this comment.
SecurityCredentials already redacts its toString. But I note we're doing such sanitizing differently in different classes (*** vs ********* vs <redacted>). It would be nice to do it consistently.
robobario
left a comment
There was a problem hiding this comment.
Thanks @tombentley, looks like a good idea.
| LOG.info("DENY {} to {}", authz.denied(), authz.subject()); | ||
| LOGGER.atInfo() | ||
| .addKeyValue("deniedActions", authz.denied()) | ||
| .addKeyValue("subject", authz.subject()) |
There was a problem hiding this comment.
consistency across the logs seems important, maybe it would be worth establishing a pattern like a LoggingKeys class per module that contains only String constants? That way you'd get a bit of autocomplete support when you come to add new logs in module X.
There was a problem hiding this comment.
We don't really have a common dependency, so we can't do that globally (hence your "per module"). Well, there's kroxylicious-annotations of course, but that would be changing its original purpose. And if we don't do it globally then the establishment of a pattern is a bit weakened.
I would guess a similar problem exists for metrics, though we have fewer of those than logging statements.
Another thing which gets repeated a lot in this PR is the "log at DEBUG for full stack trace" thing. It's desirable to encapsulate that too.
Are these things sufficient to repurpose kroxylicious-annotations, or add a kroxylicious-common ?
There was a problem hiding this comment.
if we're going to encapsulate the debug logging pattern then I think we're heading for a kroxylicious-logging type module, or your kroxylicious-common. Shoehorning it into annotations feels a bit ugly. Maybe a kroxylicious-observability would give it some leeway to have common code related to metrics too, common tag names etc.
There was a problem hiding this comment.
I mention kroxylicious-annotations because it currently contains a single annotation. It feels like that annotation could also live in a kroxylicious-common module without really losing anything.
There was a problem hiding this comment.
I'm coming to the conclusion that the cure (constants) is going to be worse than the disease (repeated string literals):
- A call site which mixes constants and literals will look ugly. Also the constants obscure the actual string value, so I can imagine we could end up with duplicate keys, but it's not apparent at the call site because of the use of constants
- Many the constants are common across the runtime and the plugins (e.g. `apiKey), but many are not. So we'll end up with lots of classes holding constants. In some cases we'll have the same value as a constant in different modules simply because there isn't a suitable common dependency to declare (yet another) class of constants.
- If we're declaring constants then we ought to document them, which just increases the burden still further.
- This is all just going to create a lot of endless but pointless churn as we find some string literal have become duplicated in a modeul and feel the need to factor it out, and later find it's also a constant in another module, so factor it into a common dependency.
This all feels like a lot more trouble that it's worth to me.
FTR this is the distribution of keys we have currently:
$ grep -rh '.addKeyValue("' | sed -E 's/^[ \t]+//g' | sed -E 's/(.addKeyValue\(".*"),.*/\1/' | sort | uniq -c | sort -n
1 .addKeyValue("advertisedAddress"
1 .addKeyValue("allowedActions"
1 .addKeyValue("ambiguousKey"
1 .addKeyValue("annotatedClass"
1 .addKeyValue("annotation"
1 .addKeyValue("attempt"
1 .addKeyValue("authenticationDisposition"
1 .addKeyValue("authorizedId"
1 .addKeyValue("authorizerClass"
1 .addKeyValue("backendHandler"
1 .addKeyValue("binder"
1 .addKeyValue("brokerMaxVersion"
1 .addKeyValue("brokerMinVersion"
1 .addKeyValue("buffer"
1 .addKeyValue("bufferReadableBytes"
1 .addKeyValue("candidates"
1 .addKeyValue("checksum"
1 .addKeyValue("cipherAlgorithm"
1 .addKeyValue("clientHost"
1 .addKeyValue("clientMechanism"
1 .addKeyValue("clientPort"
1 .addKeyValue("closeable"
1 .addKeyValue("collidingClass"
1 .addKeyValue("commitId"
1 .addKeyValue("commonMechanisms"
1 .addKeyValue("correlationId"
1 .addKeyValue("credential"
1 .addKeyValue("currentMinVersion"
1 .addKeyValue("deadline"
1 .addKeyValue("defaultPort"
1 .addKeyValue("delegate"
1 .addKeyValue("deniedActions"
1 .addKeyValue("destinationAddress"
1 .addKeyValue("destinationPort"
1 .addKeyValue("direction"
1 .addKeyValue("downstream"
1 .addKeyValue("encryptionBuffer"
1 .addKeyValue("failureCount"
1 .addKeyValue("filterDefinitionType"
1 .addKeyValue("filterReferences"
1 .addKeyValue("frameClass"
1 .addKeyValue("fromState"
1 .addKeyValue("fromVersion"
1 .addKeyValue("frontendHandler"
1 .addKeyValue("hint"
1 .addKeyValue("incomingHost"
1 .addKeyValue("incomingPort"
1 .addKeyValue("ingresses"
1 .addKeyValue("interface"
1 .addKeyValue("jreFeatureVersion"
1 .addKeyValue("kafkaProxy"
1 .addKeyValue("kafkaProxyName"
1 .addKeyValue("kafkaService"
1 .addKeyValue("kafkaServiceRefs"
1 .addKeyValue("kekId"
1 .addKeyValue("keyClass"
1 .addKeyValue("kind"
1 .addKeyValue("kmsCacheConfig"
1 .addKeyValue("kmsOperation"
1 .addKeyValue("length"
1 .addKeyValue("local"
1 .addKeyValue("localAddress"
1 .addKeyValue("maxFrameSizeBytes"
1 .addKeyValue("maxSupportedVersion"
1 .addKeyValue("mechanismStatus"
1 .addKeyValue("method", methodName + "(ApiKeys, " + headerType.getSimpleName() + "
1 .addKeyValue("minSupportedVersion"
1 .addKeyValue("name"
1 .addKeyValue("newMaxVersion"
1 .addKeyValue("newMinVersion"
1 .addKeyValue("newName"
1 .addKeyValue("oldMaxVersion"
1 .addKeyValue("oldMinVersion"
1 .addKeyValue("originalError"
1 .addKeyValue("partition"
1 .addKeyValue("pauseThresholdMs"
1 .addKeyValue("pluginInterface"
1 .addKeyValue("principalClass"
1 .addKeyValue("propertiesFile"
1 .addKeyValue("proposedMechanism"
1 .addKeyValue("provider"
1 .addKeyValue("receivedFrameSizeBytes"
1 .addKeyValue("remoteAddress"
1 .addKeyValue("remoteHost"
1 .addKeyValue("remotePort"
1 .addKeyValue("requiredMinVersion"
1 .addKeyValue("resource"
1 .addKeyValue("response"
1 .addKeyValue("route"
1 .addKeyValue("scheme"
1 .addKeyValue("secretName"
1 .addKeyValue("serverMechanisms"
1 .addKeyValue("service"
1 .addKeyValue("sleepIntervalMs"
1 .addKeyValue("sniHostname"
1 .addKeyValue("sourceAddress"
1 .addKeyValue("sourcePort"
1 .addKeyValue("stateMachine"
1 .addKeyValue("tags"
1 .addKeyValue("targetState"
1 .addKeyValue("testedJreVersion"
1 .addKeyValue("to"
1 .addKeyValue("topicId"
1 .addKeyValue("topicIds"
1 .addKeyValue("toState"
1 .addKeyValue("toVersion"
1 .addKeyValue("unsupportedActions"
1 .addKeyValue("upstream"
1 .addKeyValue("user"
1 .addKeyValue("versionStatus"
1 .addKeyValue("virtualClusters"
1 LOGGER.atInfo().addKeyValue("secret"
1 LOGGER.atWarn().addKeyValue("error"
1 return builder.addKeyValue("sessionId"
1 tns -> LOGGER.atInfo().addKeyValue("namespaces"
2 .addKeyValue("alias"
2 .addKeyValue("alreadyRead"
2 .addKeyValue("apiId"
2 .addKeyValue("cipherSpec"
2 .addKeyValue("cluster"
2 .addKeyValue("configMaps"
2 .addKeyValue("correlation"
2 .addKeyValue("decodeRequest"
2 .addKeyValue("decodeResponse"
2 .addKeyValue("delayMs"
2 .addKeyValue("encodedSize"
2 .addKeyValue("envVar"
2 .addKeyValue("expiration"
2 .addKeyValue("failures"
2 .addKeyValue("filter"
2 .addKeyValue("frameSize"
2 .addKeyValue("frameType"
2 .addKeyValue("gateway"
2 .addKeyValue("iamRole"
2 .addKeyValue("image"
2 .addKeyValue("ingress"
2 .addKeyValue("javaVendor"
2 .addKeyValue("javaVersion"
2 .addKeyValue("keyName"
2 .addKeyValue("keyVersion"
2 .addKeyValue("maxVersion"
2 .addKeyValue("minVersion"
2 .addKeyValue("oldName"
2 .addKeyValue("osArch"
2 .addKeyValue("osName"
2 .addKeyValue("osVersion"
2 .addKeyValue("outcome"
2 .addKeyValue("output"
2 .addKeyValue("pipeline"
2 .addKeyValue("pluginClass"
2 .addKeyValue("predicate"
2 .addKeyValue("providerType"
2 .addKeyValue("readable"
2 .addKeyValue("readableBytes"
2 .addKeyValue("requestApiVersion"
2 .addKeyValue("requestUri"
2 .addKeyValue("resourceIds"
2 .addKeyValue("resourceName"
2 .addKeyValue("saslState"
2 .addKeyValue("secondaryClass"
2 .addKeyValue("secrets"
2 .addKeyValue("state"
2 .addKeyValue("supportedCiphers"
2 .addKeyValue("supportedProtocols"
2 .addKeyValue("topicName"
2 .addKeyValue("unsupportedCipher"
2 .addKeyValue("unsupportedProtocol"
2 .addKeyValue("url"
2 .addKeyValue("validationResult"
2 .addKeyValue("version"
2 .addKeyValue("virtualCluster"
3 .addKeyValue("address"
3 .addKeyValue("authenticationState"
3 .addKeyValue("authorizationId"
3 .addKeyValue("bindAddress"
3 .addKeyValue("dek"
3 .addKeyValue("downstreamCorrelationId"
3 .addKeyValue("filterName"
3 .addKeyValue("headerVersion"
3 .addKeyValue("kekRef"
3 .addKeyValue("out"
3 .addKeyValue("responseBody"
4 .addKeyValue("context"
4 .addKeyValue("endpoint"
4 .addKeyValue("errorCode"
4 .addKeyValue("filterClass"
4 .addKeyValue("mechanism"
4 .addKeyValue("port"
4 .addKeyValue("proxyIds"
4 .addKeyValue("remote"
5 .addKeyValue("header"
6 .addKeyValue("channelId"
6 .addKeyValue("clientId"
6 .addKeyValue("message"
6 .addKeyValue("upstreamCorrelationId"
7 .addKeyValue("body"
7 .addKeyValue("statusCode"
10 .addKeyValue("apiVersion"
10 .addKeyValue("subject"
11 .addKeyValue("frame"
23 .addKeyValue("error"
28 .addKeyValue("ctx"
34 .addKeyValue("apiKey"
34 .addKeyValue("sessionId"
There was a problem hiding this comment.
ah sonar is complaining about 3 usages. A bit low for this purpose. Pain, in other circumstances 3+ could be a good signal, but not so much here.
There was a problem hiding this comment.
@robobario I've pushed up some changes which use the module-local constants approach, if you wanted to take a look. It doubles the diffstat
Let me know!
There was a problem hiding this comment.
^ yep as said above, String literals sounds good to me, go ahead and revert.
5ae22ec to
c2aab0b
Compare
|
+1 to the idea. Did you consider some programmatic checks to keep production code from regressing? I asked Claude it suggested checkstyle would be a reasonable fit for the project. Here's the result tombentley#62 |
Update Log4j2 configuration files to render key-value pairs from
the SLF4J fluent API using %K{ctx} pattern marker. This enables
structured logging while maintaining backwards compatibility with
existing log parsing tools.
Changes:
- Add %K{ctx} to PatternLayout in production configs (app, operator)
- Add %K{ctx} to test configurations for consistency
The pattern %replace{ %K{ctx}}{' $'}{} ensures clean output:
- Appends key-value pairs as: key1=value1 key2=value2
- Removes trailing space when no key-values present
Assisted-by: Claude Sonnet 4.5 <[email protected]>
Signed-off-by: Tom Bentley <[email protected]>
…format Convert all logging statements in the runtime module from traditional parameterised style and .addArgument() to fluent API with .addKeyValue() for structured, machine-parseable logs. Changes: - Convert ~150+ logging statements across 31 files - Use .addKeyValue() with camelCase keys (sessionId, apiKey, etc.) - Remove unnecessary isDebugEnabled() guards (fluent API is lazy) - Preserve conditional stack traces pattern - Use supplier functions for expensive toString() operations - Message describes WHAT happened, key-values provide context Key files refactored: - FilterHandler, ProxyChannelStateMachine, KafkaProxy - ServiceBasedPluginFactoryRegistry, VirtualClusterModel - All codec files (KafkaRequest/ResponseDecoder/Encoder, CorrelationManager) - All net files (EndpointRegistry, NetworkBind/UnbindRequest) - All proxy handlers (Frontend, Backend, Initializer) - All frame and filter utility files All runtime tests pass. Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…ue format Convert all logging from .addArgument() to .addKeyValue() for structured logging. The filter already used fluent API but was using positional arguments with setMessage() instead of named key-value pairs. Changes: - Convert 3 logging methods to use .addKeyValue() - Use descriptive keys: sessionId, subject, key, version, error - Preserve conditional stack trace pattern - Messages now describe WHAT happened, keys provide context All entity-isolation tests pass. Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…e format - Convert all logging to fluent API with addKeyValue() - Use structured key-value pairs for context - Apply consistent key naming: mechanism, clientId, authenticationState, channelDescriptor - Maintains semantic equivalence with previous logging Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…lue format - Convert all logging to fluent API with addKeyValue() - Use structured key-value pairs for context - Apply consistent key naming: kmsOperation, kekId, cipherSpec, encryptionBuffer - Maintains semantic equivalence with previous logging Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…ue format - Convert all logging to fluent API with addKeyValue() - Use structured key-value pairs for context - Apply consistent key naming: topicId, topicName, errorCode, failureCount - Maintains semantic equivalence with previous logging Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…ey-value format - Convert all logging to fluent API with addKeyValue() - Use structured key-value pairs for context - Apply consistent key naming: saslState, error - Maintains semantic equivalence with previous logging Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…lue format - Convert all logging to fluent API with addKeyValue() - Use structured key-value pairs for context - Apply consistent key naming: validationResult - Maintains semantic equivalence with previous logging Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
Remove logging of DEK objects to comply with security requirement that plaintext key material must never be logged. The previous TRACE logging was outputting DEK toString() which could expose key material. Changes: - Convert remaining trace logging to fluent style - Remove DEK object from log output (security requirement) - Log only the action, not the key material This fixes a security vulnerability where DEKs could be exposed in trace-level logs. Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
Signed-off-by: Tom Bentley <[email protected]>
Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. Changes: - Use .addKeyValue() for structured context - Apply conditional stack traces in error paths - Lowercase, concise log messages - Keys: keyClass, error Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…th key-value format Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. Changes: - Use .addKeyValue() for structured context - Apply conditional stack traces in error paths - Lowercase, concise log messages - Keys: delayMs, iamRole, error, expiration, credential Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…style with key-value format Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. Changes: - Convert .addArgument() to .addKeyValue() for consistency - Use .addKeyValue() for structured context - Apply conditional stack traces in error paths - Lowercase, concise log messages - Keys: kekRef, error, responseBody, requestUri, statusCode Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…le with key-value format Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. Changes: - Use .addKeyValue() for structured context - Apply conditional stack traces in error paths - Lowercase, concise log messages - Keys: delayMs, error, expiration, statusCode Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
… to fluent style with key-value format Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. This commit covers the core AzureKeyVaultKms class. Token service classes will be updated in a subsequent commit. Changes: - Use .addKeyValue() for structured context - Lowercase, concise log messages - Keys: keyName, keyVersion Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…s) logging to fluent style with key-value format Convert logging statements from traditional string interpolation to the SLF4J fluent API with structured key-value pairs. This provides machine-parseable log output for better observability whilst maintaining human readability. This commit covers the Azure token service classes: CachingBearerTokenService, ManagedIdentityAccessTokenService, and OauthClientCredentialsTokenService. Changes: - Use .addKeyValue() for structured context - Apply conditional stack traces in error paths - Lowercase, concise log messages - Keys: fromState, toState, error, statusCode Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
Make the "increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: DestroyableRawSecretKey.java Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
Make the "Increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: Ec2MetadataCredentialsProvider.java Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…rp-vault Make the "increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: VaultKms.java (2 occurrences) Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…x-dsm Make the "increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: ApiKeySessionProvider.java (2 occurrences) Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…ey-vault-kms Make the "increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: ManagedIdentityAccessTokenService.java, OauthClientCredentialsTokenService.java Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
Make the "increase log level to DEBUG for stacktrace" suffix conditional on the DEBUG level. When DEBUG is enabled, the message no longer includes this suffix since the stack trace is already being logged. This improves log clarity by ensuring messages are contextually appropriate for the current logging level. Changes: - Apply conditional message suffix based on DEBUG level - Affected: ProxyChannelStateMachine.java (2 occurrences), FilterHandler.java, KafkaProxyInitializer.java Assisted-by: Claude Sonnet 4.5 <[email protected]> Signed-off-by: Tom Bentley <[email protected]>
…eys" This reverts commit ae0921a. Signed-off-by: Tom Bentley <[email protected]>
…eys" This reverts commit 05f58b8. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 1dba388. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 0e81574. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit e64ec1d. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit fb0b3a1. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 69f75d9. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 946924a. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 69f7350. Signed-off-by: Tom Bentley <[email protected]>
…Keys" This reverts commit 3c79f84. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 52b8b62. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit e06a751. Signed-off-by: Tom Bentley <[email protected]>
…gKeys" This reverts commit efbffc5. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit caa172a. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 2b45fd6. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 1e5f31b. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 3437947. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 7db67d0. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 3f83909. Signed-off-by: Tom Bentley <[email protected]>
This reverts commit 6a1e6aa. Signed-off-by: Tom Bentley <[email protected]>
f55870c to
0df7fab
Compare
with tokens within production code. Signed-off-by: Keith Wall <[email protected]> Assisted-by: Claude Sonnet 4.5 <[email protected]>
|
|



Type of change
Description
Migrate Kroxylicious logging to structured key-value format using SLF4J fluent API, with optional JSON output support.
Benefits
Core Migration
%K{ctx}pattern to render key-value pairsJSON Logging Support
KROXYLICIOUS_LOG_FORMATenvironment variable to switch between text and JSON outputPatternLayout(text, default) andJsonTemplateLayout(JSON)Standardisation
LOGGERacross all moduleschannelDescriptorwithsessionIdin key-value pairs (except a few places in the runtime)Additional Context
Over time our logging has grown a few inconsistencies.
This PR seeks to apply more consistency in how we do logging within the project.
Assisted-by: Claude Sonnet 4.5 [email protected]
Checklist
Please go through this checklist and make sure all applicable tasks have been done