Skip to content

Commit

Permalink
Update source link
Browse files Browse the repository at this point in the history
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=206154568
  • Loading branch information
emosenkis authored and ronshapiro committed Aug 24, 2018
1 parent 1b447d1 commit 12aea6a
Show file tree
Hide file tree
Showing 14 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ included when the binary is run. If you have a modularized build, you can
include this dependency by the root module that builds your app/binary, and can
be `runtime` scope.

<!-- TODO(user): link to docs for how to specify a backend. -->
<!-- TODO(dbeaumont): link to docs for how to specify a backend. -->

### 2. Add an import for [`FluentLogger`]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public final API atFinest() {
// backend API to be flexible enough _not_ to admit the existence of the JDK logger, we will
// need to push the LoggerConfig API down into the backend and expose it from there.
// See b/14878562
// TODO(user): Make anonymous loggers work with the config() method and the LoggerConfig API.
// TODO(dbeaumont): Make anonymous loggers work with the config() method and the LoggerConfig API.
protected String getName() {
return backend.getLoggerName();
}
Expand Down
2 changes: 1 addition & 1 deletion api/src/main/java/com/google/common/flogger/LogSite.java
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ public boolean equals(Object obj) {
@Override
public int hashCode() {
if (hashcode == 0) {
// TODO(user): Revisit the algorithm when looking at b/22753674.
// TODO(dbeaumont): Revisit the algorithm when looking at b/22753674.
// If the log statement uses metadata, the log site will be used as a key to look up the
// current value. In most cases the hashcode is never needed, but in others it may be used
// multiple times in different data structures.
Expand Down
6 changes: 3 additions & 3 deletions api/src/main/java/com/google/common/flogger/LoggerConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public final class LoggerConfig {
* The number of loggers on which configuration occurs should be small and effectively bounded
* in all expected use cases, so it should be okay to retain all of them for the life of a task.
*/
// TODO(user): Reassess the risk of memory leaks here and decide what to do about it.
// TODO(dbeaumont): Reassess the risk of memory leaks here and decide what to do about it.
private static final Map<String, LoggerConfig> strongRefMap =
new ConcurrentHashMap<String, LoggerConfig>();

Expand All @@ -75,7 +75,7 @@ public final class LoggerConfig {
* @param fluentLogger the name of the logger to be configured via this API.
*/
public static LoggerConfig of(AbstractLogger<?> fluentLogger) {
// TODO(user): Revisit if/when Flogger supports anonymous loggers.
// TODO(dbeaumont): Revisit if/when Flogger supports anonymous loggers.
checkArgument(fluentLogger.getName() != null,
"cannot obtain configuration for an anonymous logger");
return getConfig(fluentLogger.getName());
Expand Down Expand Up @@ -120,7 +120,7 @@ public static LoggerConfig getConfig(String name) {
LoggerConfig config = strongRefMap.get(checkNotNull(name, "logger name"));
if (config == null) {
// Ignore race condition of multiple put as all instances are equivalent.
// TODO(user): Add a check and warn if the map grows "too large".
// TODO(dbeaumont): Add a check and warn if the map grows "too large".
config = new LoggerConfig(name);
strongRefMap.put(name, config);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ public FormatOptions filter(int allowedFlags, boolean allowWidth, boolean allowP
// This check would be faster if we encoded the entire state into a long value. It's also
// entirely possible we should just allocate a new instance and be damned (especially as
// having anything other than the default instance is rare).
// TODO(user): Measure performance and see about removing this code, almost certainly fine.
// TODO(dbeaumont): Measure performance and see about removing this code, almost certainly fine.
if (newFlags == flags && newWidth == width && newPrecision == precision) {
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ private static StringBuilder formatMessage(LogData logData) {
new SimpleMessageFormatter(logData.getTemplateContext(), logData.getArguments());
StringBuilder out = formatter.build();
if (logData.getArguments().length > formatter.getExpectedArgumentCount()) {
// TODO(user): Do better and look at adding formatted values or maybe just a count?
// TODO(dbeaumont): Do better and look at adding formatted values or maybe just a count?
out.append(EXTRA_ARGUMENT_MESSAGE);
}
return out;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public DefaultPlatform() {
this.context = (context != null) ? context : EmptyLoggingContext.getInstance();
Clock clock = resolveAttribute(CLOCK, Clock.class);
this.clock = (clock != null) ? clock : SystemClock.getInstance();
// TODO(user): Figure out how to handle StackWalker when it becomes available (Java9).
// TODO(dbeaumont): Figure out how to handle StackWalker when it becomes available (Java9).
this.callerFinder = StackBasedCallerFinder.getInstance();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public static SimpleLogRecord error(RuntimeException error, LogData data) {

private SimpleLogRecord(LogData data) {
super(data);
// TODO(user): Maybe we do want to do formatting on demand.
// TODO(dbeaumont): Maybe we do want to do formatting on demand.
// This would avoid formatting when the caller will just get the structured data via the
// LogData API, or when the record is filtered. However neither of these are happening at the
// moment and when structured data is required, a different log record should be used.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public static StackTraceElement findCallerOf(Class<?> target, Throwable throwabl
// This should only happen is the caller was not found on the stack (getting exceptions from
// the stack trace method should never happen) and it should only be an
// IndexOutOfBoundsException, however we don't want _anything_ to be thrown from here.
// TODO(user): Change to only catch IndexOutOfBoundsException and test _everything_.
// TODO(dbeaumont): Change to only catch IndexOutOfBoundsException and test _everything_.
return null;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ public void testNullArgument() {
// arguments to a log statement the message is a literal, which makes this situation very
// unlikely and probably a code bug (but even then throwing an exception is something that will
// only happen when the log statement is enabled).
// TODO(user): Consider allowing this case to work without throwing a runtime exception.
// TODO(dbeaumont): Consider allowing this case to work without throwing a runtime exception.
@Test
public void testNullMessageAndArgument() {
FakeLoggerBackend backend = new FakeLoggerBackend();
Expand Down
2 changes: 1 addition & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ included when the binary is run. If you have a modularized build, you can
include this dependency by the root module that builds your app/binary, and can
be `runtime` scope.

<!-- TODO(user): link to docs for how to specify a backend. -->
<!-- TODO(dbeaumont): link to docs for how to specify a backend. -->

### 2. Add an import for [`FluentLogger`]

Expand Down
2 changes: 1 addition & 1 deletion google/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ java_library(
],
deps = [
"@google_bazel_common//third_party/java/error_prone:annotations",
# TODO(user): Split this so truly public things can be exported
# TODO(dbeaumont): Split this so truly public things can be exported
# without needing implementation to be visible to the world.
"@google_bazel_common//third_party/java/jsr305_annotations",
"//api",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
* @param <API> The api returned during method chaining (possibly an extension of this interface).
*/
// NOTE: new methods to this interface should be coordinated with google-java-format
// TODO(user): Now that this class offers no additional methods, consider removing it.
// TODO(dbeaumont): Now that this class offers no additional methods, consider removing it.
@CheckReturnValue
public interface GoogleLoggingApi<API extends GoogleLoggingApi<API>> extends LoggingApi<API> {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
/**
* Tests for the Google specific extensions to Fluent Logger.
*/
// TODO(user): Make this use a fake/test backend rather than relying on the system one.
// TODO(dbeaumont): Make this use a fake/test backend rather than relying on the system one.
@RunWith(JUnit4.class)
public class GoogleLoggerTest {
// Metadata keys (single keys will be the most common).
Expand Down

0 comments on commit 12aea6a

Please sign in to comment.