RabbitMQ producer sends user balance >= 0 to astakos
Added RabbitMQProducer.scala. The code has been tests and works. "rabbitmq.imevents.credit=astakos:astakos-events-credit" must be added in aquarium.properties
Fix bad handling of IMEvent from the UserActor.
Upon arrival of the first IMEvent and after some ResourceEvents hadalready arrived at the UserActor, we got an exception due to useragreements beeing empty (being empty is reasonable, since there were noIMEvent previously)....
Removed timeslot computations print statements
Fixed data race in caching polict store. Restored some code from timeslot computations
Wallets go REST
There is a bug related to the timeslot computations, so I had to disableevery piece that computes fine-grained timeslots and their corresponingstuff (agreement).
Add a UserStateModelSkeleton
Unimplemented operations on PolicyStore return safe results
Better handling of billing month info
Ensure the cache is loaded before inserting
Slash'em high
Fix NPE with initial user state
Initializing the policy store the very first time
If the DB is empty, then we insert the default policy, as given in thepolicy.json file.
TimerService is concrete now
Applying the new policy semantics everywhere
added implementation for MemStoreProvider (PolicyStore methods)
Test cases for EffectUnitPrice
policyStore is now a val ! Not a def
Implemented PolicyHistory.scala (a cache that wraps Database calls) and modified various bits and pieces
Manually revert to ddd366d
more test cases
Merge remote-tracking branch 'origin/master'
removed deprecated DSL*.scala files
Fix imports
Remove obsolete files
Fix a compilation error (did not implement a MemStore method)
DSLUtils is now deprecated. Implemented the functionality of EffectivePriceUnit.scala, added CronSpec.scala and moved a few methods from DSLUtils to TimeslotComputations.scala
WIP chargeslot computations
Remove one redundant parameter in charging computations
Add correct prefix to a mongodb configuration parameter
Second cut of the new policy configuration system
Major changes. Does not compile. Will need a third round.
First cut of the new policy configuration system
This is to replace the existing DSLXXX stuff for several reasons:
- Maps better to user requirements.- Is simpler to state and implement and thus can be better tested.- Is also flexible but with clearer semantics....
Timespecs should be working ok now!
Remove redundant call to AquariumAware
This is automatically done inside newInstance() now.
A bit more informative documentation
Remove unused statement
Consider a forgotten match case
Note that the now two last cases can be merged to one like this:
- case _ => ...
but we keep them separate just to make it clear what is going on and toeasily change the response for each case if such a need arises.
Properly handle user actor eviction
Rename the functional interface of AquariumAware
More internal info exposed via the protected REST api
Configuring all new instances that are AquariumAware
Showing the available processors upon starting
Showing the propertied prefix of the configured instance
Do not throw exceptions at the browser's face
Fix a bug with class casting to the wrong future type
Upgrade Akka to 2.0.2
In the process, cleaned up code and make a few changes for more robustactor cache handling.
Remove spray configuration
Remove unused pinger actor
Return 404 when no user state is found
Configure aquarium when creating the user actor
Use finagle instead of spray for the REST functionality
Not tested yet
Remove imports that generate compilation warnings
Merge commit '695c71e20f5a068757525453e76792914b15b2bd'
Refactor Aquarium to make it more configurable
- No Aquarium singleton any more.- Aquarium is bootstrapped and configured using a builder.- Services are wired a bit differently right now. Needs more testing, in order to reach previous runtime stability.
Several fixes and refactorings ins package logic.acounting.dsl
Always calculate wallet entries
Cost policy generalizations
Use the whole event instead of tis value for decision making andcomputations. This was long in the todo list, time to apply it now.
Trimming down the interface of cost policy
I accidentally committed on the debian branch. Cherry-picking the latestcommit here generated some conflicts.
Conflicts: src/main/scala/gr/grnet/aquarium/logic/accounting/dsl/DSLCostPolicy.scala
Fix policy effectiveness period
Previously, the policy loaded from policy.yaml was taken to be effectivestarting from the time the loading happended. Normally, we need to seta proper effectivess period for the policy. Until then and in order forsome other test cases to proceed, we consider a better starting time.
WIP Resource event handling
- Boundary conditions for first events
WIP Resource event handling and API cleanup
Organize a few rest paths
Introduce error tags
The rationale is:- To have a centralized view of what error conditions can appear in Aquarium.- To use consistent error descriptions, in case where an error condition applies to more than one place.
This is of course an initial approach. Let's see how it goes.
Add two more REST internal calls
- Get rc event by id.- Get im event by id.
Calls are protected by the admin.cookie property
Internal REST calls go through a header check
Expose via REST some useful info
Being devops-friendly until a user creation event arrives
Small doc: We ignore everything except serious errors
Rework billing month info
We are more JSON-friendly, without the need for custom type hints forlift-json.
Add one more logging utility method
Small clarification regarding loading logging configuration
Adjust default aquarium.properties
Reenable custom logging configurarion loading
Print more logging info while starting up
Make sure UserStateChangeReasons are properly serialzed to JSON (via json-lift)
WIP event handling: Initialization fixes
Add comments for the functions needed in payload handlers
HandlerResultPanic acquires a reason
Add doc in PayloadHandler
Better logging in generic payload handler
Use SynchronousPayloadHandlerExecutor. For now
Better formatting in localfs evetn store
Add logChainOfCauses to LogHelpers
WIP event handling
Add one small utility method for obtaining a short version of a type name
Remove unused class
Separate rabbitmq configuration keys from the rabbitmq service
Remove obsolete wallet entry
Add TODO for future optimization
Work in progress on handling user state
I just committed everything. Not sure what will survive yet.
More complete handling of IM events
Expose some debugging facilities in Aquarium class
Fix compilation error due to API change in rabbitmq client lib
Keep LRU from guava libraries