Commit Graph

37 Commits

Author SHA1 Message Date
Chris Meyers
eb27233e5c clear insights system id if not found
* Host previously found to have an insights system id that then later
are found to not have an insights system id, have their system id
cleared.
2017-05-12 12:00:30 -04:00
Chris Meyers
3cdc332497 rename insight tracking field; handle duplicate
* rename from insights_machine_id to insights_system_id
* gracefully handle duplicate insights machine id's
2017-05-12 10:47:49 -04:00
Chris Meyers
b9b0b29d97 associate insights machine id w/ host on fact scan
* Add inisghts fact scan module
* Update fact scan playbook to call new insight fact scan module
* JT run w/ store_facts=True will save scanned facts. We "skim" the
machine_id fact from Insights fact scans and associate it with the host
that the fact scan came from.
2017-05-11 11:20:52 -04:00
Chris Meyers
0be384af18 rename field to store_facts and fix up tests 2017-05-01 16:39:48 -04:00
Chris Meyers
6dec9d1014 per-jt most recent fact scan gathering
* Remove system tracking piggybacked most-recent-fact-gathering
* Add explicit per-jobtemplate configurable fact gathering
* Continue to support system tracking
* Fixed a bug where we weren't ack()ing system tracking rabbit msgs
2017-05-01 16:03:16 -04:00
Chris Meyers
4795fd28bf always gather facts
* bolt on the fact scan gather to all jobs
2017-05-01 16:03:16 -04:00
Chris Meyers
d14a55911b ack fact scan messages
* Fixes a bug where fact rabbit messages would build up because we never
explicitly ack them.
2017-04-28 13:46:54 -04:00
AlanCoding
7344a998b2 move formatter to logger file, settings reload on startup 2016-12-01 19:09:55 -05:00
Matthew Jones
9cecb7d870 Cleaning up some parts of the logging branch
* Fixing some flake8 warnings
* Removing some superflous print statements
2016-11-29 15:02:20 -05:00
AlanCoding
f3427d1359 Logging Integration, ELK docker-compose as update file 2016-11-29 13:09:47 -05:00
Matthew Jones
35b9786e06 Fixing up fact cachine related unit tests 2016-11-18 10:23:07 -05:00
Matthew Jones
3b07d9745d Port fact caching system to rabbitmq
* Purge all references to zmq also
* New setting to control the queue it works on
2016-11-18 09:44:17 -05:00
Aaron Tan
9e4655419e Fix flake8 E302 errors. 2016-11-15 20:59:39 -05:00
Matthew Jones
0c1e1fa2fb Refactor Tower HA Instance logic and models
* Gut the HA middleware
* Purge concept of primary and secondary.
* UUID is not the primary host identifier, now it's based mostly on the
  username.  Some work probably still left to do to make sure this is
  legit.  Also removed unique constraint from the uuid field.  This
  might become the cluster ident now... or it may just deprecate
* No more secondary -> primary redirection
* Initial revision of /api/v1/ping
* Revise and gut tower-manage register_instance
* Rename awx/main/socket.py to awx/main/socket_queue.py to prevent
  conflict with the "socket" module from python base
* Revist/gut the Instance manager... not sure if this manager is really
  needed anymore
2016-09-08 13:37:53 -04:00
Akita Noek
b57739a800 Converted except T,e expressions to except T as e 2016-06-27 15:12:37 -04:00
Chris Meyers
e7d68409f7 fix scan job timestamp 2016-04-12 17:07:11 -04:00
Chris Meyers
220d4c635e fix fact cache receiver 2016-03-09 14:41:54 -05:00
Chris Meyers
5759db1229 flake8 fix 2016-03-04 14:14:10 -05:00
Chris Meyers
7494b13704 find correct fact to update
* The fact cache receiver needs to look for an exact match, rather than
* a relative, most recent fact.
2016-03-04 11:41:08 -05:00
Chris Meyers
7ffe46fc74 add postgres Fact model, update views, tests
* awx.main.models Fact added
* view host fact and timeline updated to use new Postgres Fact model instead of Mongo
* Removed license set start Mongo logic
* added View tests
* added Model tests
* Removed mongo fact unit tests
* point at modified jsonbfield that supports sqlite storage driver
* postgresify fact cache receiver
* test OPTIONS endpoint
* Note: single fact view not implemented yet.
2016-02-24 14:38:54 -05:00
Matthew Jones
2f39393cf3 Implement fact receiver thread worker
Optionally allow processing of fact receiver messages in a worker
thread.  This works around an issue where data could take a while to
page into Mongo and cross the zmq socket timeout.
2015-08-28 10:59:52 -04:00
Chris Meyers
713f18438c added more logging for fact cache receiver 2015-06-24 14:07:18 -04:00
Chris Meyers
d5b7be3f4f Merge pull request #276 from chrismeyersfsu/fix-fact_inventory_relationship
associate scan runs with a particular inventory host
2015-06-11 20:55:13 -04:00
John Mitchell
32d1c0e4db fixed copyright date 2015-06-11 16:10:23 -04:00
Chris Meyers
0c7638bdd7 associate scan runs with a particular inventory host 2015-06-11 15:14:00 -04:00
Matthew Jones
3c2f3f323a Fix some flake8 2015-06-09 16:07:06 -04:00
Matthew Jones
ab5c4b5f20 Check connection for scan jobs before actually running the job, fail
early if the system tracking database isn't available
2015-06-09 15:31:23 -04:00
Matthew Jones
e392add46f Catch exceptions if there are issues communicating with mongo 2015-06-01 16:00:11 -04:00
Matthew Jones
31d0342d41 More copyright headers for api side stuff 2015-05-29 12:10:40 -04:00
Chris Meyers
c2a87bbb53 allow user provided fact scan modules 2015-05-12 09:39:37 -04:00
Chris Meyers
2a039bb31f moved new fact implementation to fact app 2015-04-07 09:50:35 -04:00
Chris Meyers
a769af0e83 flake8 fixes 2015-04-07 09:50:35 -04:00
Chris Meyers
c03cef022d Implemented fact scan storage logic.
* added mongo connection logic
* added mongo dbtransform logic to allow keys with . and $
* altered tower fact scanner CacheModule to emit a message for each fact module facts (including ansible facts). Previously, seperate facts module facts were getting concatenated to each subsequent emi
* tower fact scanner CacheModule timeout set as to not hang for forever
* broke apart commands.py test
* added unit test for run_fact_cache_receiver, facts, and dbtransform
2015-04-07 09:50:35 -04:00
Matthew Jones
dd44c0a0f2 Initial implementation of the service scanner module 2015-03-19 13:21:45 -04:00
Matthew Jones
70f2e5ea1d Handle unifying the datetime value as a key that we can update on the
tower side
2015-02-20 17:19:19 -05:00
Matthew Jones
fd1668dfd8 Implement fact caching service and mongo reference handler 2015-02-20 16:56:35 -05:00
Matthew Jones
fed4262ee2 Some light implimentation details for basic fact caching and collection 2015-02-19 11:27:40 -05:00