When EAP is involed we current have one billing event for domain create that
has the create fee and EAP fee lumped together. Change it to record two
separate billing events for each.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=132335349
This is one of a series of CLs adding a new metric type, EventMetric, which
is used for tracking numerical distributions.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=132103552
This work is identical to the work done for BackendServlet in
[]
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=132100448
It's better that it always takes a non-null ImmutableSet, which may either be
empty or contain elements. That way the ugliness of nullness is contained
just to the entity class itself, and all other code that interacts with it
can always be assured of having a real set to deal with.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=132066238
This is the first step in consolidating our task queues down into a smaller
number. We have lots of tasks that run quite infrequently, and they can all run
in the same queue to get retry semantics without needing a new queue for each
cron entry.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131990472
The backfill for these is no longer necessary as all of the Registry entities in all environments have been backfilled.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131984138
This change replaces all Ref objects in the code with Key objects. These are
stored in datastore as the same object (raw datastore keys), so this is not
a model change.
Our best practices doc says to use Keys not Refs because:
* The .get() method obscures what's actually going on
- Much harder to visually audit the code for datastore loads
- Hard to distinguish Ref<T> get()'s from Optional get()'s and Supplier get()'s
* Implicit ofy().load() offers much less control
- Antipattern for ultimate goal of making Ofy injectable
- Can't control cache use or batch loading without making ofy() explicit anyway
* Serialization behavior is surprising and could be quite dangerous/incorrect
- Can lead to serialization errors. If it actually worked "as intended",
it would lead to a Ref<> on a serialized object being replaced upon
deserialization with a stale copy of the old value, which could potentially
break all kinds of transactional expectations
* Having both Ref<T> and Key<T> introduces extra boilerplate everywhere
- E.g. helper methods all need to have Ref and Key overloads, or you need to
call .key() to get the Key<T> for every Ref<T> you want to pass in
- Creating a Ref<T> is more cumbersome, since it doesn't have all the create()
overloads that Key<T> has, only create(Key<T>) and create(Entity) - no way to
create directly from kind+ID/name, raw Key, websafe key string, etc.
(Note that Refs are treated specially by Objectify's @Load method and Keys are not;
we don't use that feature, but it is the one advantage Refs have over Keys.)
The direct impetus for this change is that I am trying to audit our use of memcache,
and the implicit .get() calls to datastore were making that very hard.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131965491
The absence of the service account scopes was causing a NullPointerException
when the Google groups syncing action was running.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131870610
This is one of a series of CLs which will refactor EppMetrics into a value type
and Metrics into a stateless class which will have an export(EppMetrics requestDetails)
method to export EPP metrics in a stateless way. Once EppMetrics is a value
type, I will create a new StackdriverEppMetrics that will also accept the value
type via an incrementRequests(EppMetrics requestDetails), allowing us to
monitor EPP via BigQuery and Stackdriver with minimum code duplication.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131711810
Checks are added to ensure that fees are always non-negative, while credits are always negative, as required by the EPP fee extension specification. Also, BaseFee is made specifically abstract.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131620110
This is needed for a soon-to-be-submitted CL that changes
all Refs to Keys and therefore removes the logic in
toHydratedString that doesn't expand Keys. We need to be
able to tag types as unexpandable to avoid cycles. It
would be better to tag fields, not types, but that is a
much harder change and not currently needed by the use
case of the following CL, so for now this suffices.
While I am in here, add tests for all of the features
of toHydratedString.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131618634
The major changes are using the ExpectedException rule instead of a try/catch
pattern, asserting the message for thrown exceptions, defaulting to JUnit4
unless Mockito is really necessary, and making each test examine one behavior.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131211346
We've continuously had concurrent modification exceptions for our regularly
occurring []s that run on thousands of shards, perhaps unnecessarily so.
These exceptions started after the last major [] framework refactoring,
which changed the default number of shards from 100 to essentially infinite. I
don't think infinite is the way to go, and 100 shards should be more than
sufficient for anything we're currently running.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131175353
Currently, it's forbidden for custom metrics to write to the gae_app resource
type.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131076789
We use {EPP resource}{action} as the naming scheme everywhere else, so we shoudl do so here too. It's generally nicer for files to group by type of EPP resource (so all of the domain actions are together) than by type of action.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130955192
This CL also adds IncrementableMetric#reset() methods to allow resetting the
value and start timestamp of IncrementableMetrics.
This is necessary because some backends, like Stackdriver, use non-monotonic
changes in cumulative metric values to detect timeseries restarts. Tracking and
re-setting the start timestamp allows users to track mostly monotonic metrics
which may have non-monotonic discontinuities.
See https://cloud.google.com/monitoring/api/ref_v3/rest/v3/TimeSeries#Point for
more details.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130795229
It's superseded by RequestHandler's processing of @Action(requireLogin = true), and is no longer used anywhere:
[]
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130788873
This change enforces that IncrementableMetrics should only monotonically
increase in value, and adds a new increment() method to increment by one, which is slightly faster than incrementBy (due to a lack of non-negative checking) in the common case that the counter should only be incremented by one.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130578421
Add additional logic to handle cases when a MetricDescriptor is already defined
on the server, fix an NPE in related code, and add additional tests to ensure
that TimeSeries created from native MetricPoints are well-formed.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130555708
This change enforces URL-like metric names to match the behavior of
Stackdriver. The StackdriverWriter no longer prepends a slash, which was a
crutch.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130537347
According to the ICAAN operation profile:
2.1.7. Registries MUST support lookup for entities with the registrar role within other objects using the handle (as described in 3.1.5 of RFC7482). The handle of the entity with the registrar role MUST be equal to IANA Registrar ID. The entity with the registrar role in the RDAP response MUST contain a publicIDs member to identify the IANA Registrar ID from the IANA’s Registrar ID registry. The type value of the publicID object MUST be equal to IANA Registrar ID.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=130452501