Jira (PDB-1450) Add deactivated node timestamp to wire format

3 views
Skip to first unread message

Ryan Senior (JIRA)

unread,
Apr 23, 2015, 1:34:24 PM4/23/15
to puppe...@googlegroups.com
Ryan Senior created an issue
 
PuppetDB / New Feature PDB-1450
Add deactivated node timestamp to wire format
Issue Type: New Feature New Feature
Assignee: Unassigned
Created: 2015/04/23 10:33 AM
Fix Versions: PDB 3.0.0
Priority: Normal Normal
Reporter: Ryan Senior

Currently the deactivated node field is just a boolean. This doesn't work well in an HA/Replicated world. Instead if we include a timestamp (from the puppet master), so the date can be replicated.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.3.15#6346-sha1:dbc023d)
Atlassian logo

Ryan Senior (JIRA)

unread,
Apr 23, 2015, 1:35:30 PM4/23/15
to puppe...@googlegroups.com
Ryan Senior updated an issue
Change By: Ryan Senior
Sprint: PuppetDB 2015-05-06

Wyatt Alt (JIRA)

unread,
Apr 23, 2015, 2:01:00 PM4/23/15
to puppe...@googlegroups.com
Wyatt Alt updated an issue
Change By: Wyatt Alt
Story Points: 3

Russell Mull (JIRA)

unread,
Apr 23, 2015, 6:08:02 PM4/23/15
to puppe...@googlegroups.com
Russell Mull commented on New Feature PDB-1450
 
Re: Add deactivated node timestamp to wire format

A maybe good deactivation plan, from a discussion with Ryan Senior:

  • We should think of three states:
  • Decomissioning is done by the user, and has a producer_timestamp. It commutes with other commands.
  • Deactivation is triggered internally.
  • Deletion is also triggered internally.
  • Decomissioning commands need to be replicated
  • A good place for this may be in the /nodes endpoint
  • Let the user optionally query for decommissioned nodes
  • When pulling from a remote PDB, look at the producer_timestamp on each record. If, according the the producer_timestamp and your local clock and deactivation/deletion rules this record would be deleted, don't pull it over.

Russell Mull (JIRA)

unread,
Apr 24, 2015, 12:40:57 PM4/24/15
to puppe...@googlegroups.com
Russell Mull commented on New Feature PDB-1450

Further discussion:

The deactivated status DOES need to be replicated. Consider this case:

  • X and Y have the same active node.
  • Partition the network
  • Y receives an update
  • Y's TTL expires, auto-deactivating a node
  • Heal the partition
  • Sync, but X's TTL hasn't yet expired

In this case, X should get the updated state and keep the node active, locally.

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:10:02 PM4/24/15
to puppe...@googlegroups.com
Russell Mull commented on New Feature PDB-1450

Here's the plan:

  • User-deactivated nodes (via the puppet deactivate command) will continue to be called 'deactivated', for consistency.
  • Automatically deactivated nodes will be called 'expired'.
    • add a boolean expired column to the certnames table
    • update existing code that checks if a node is deactivated to also check if it's expired.
  • When processing the 'deactivate node' command for a certname that doesn't exist, create a new entry instead of ignoring it
  • When pulling data as part of sync
    • include deactivated and expired records in each summary query
    • only pull over records that would not be expired locally
  • Allow users to include deactivated and expired records in query results
    • at least for the factsets, catalogs, reports, and nodes endpoints
    • ...but hopefully in a generic way for all endpoints
  • Add the 'nodes' endpoint to the sync, for pulling over deactivation status
    • Include the node's deactivation time in the summary query

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:11:08 PM4/24/15
to puppe...@googlegroups.com
Russell Mull updated an issue
 
Make automatic deactivation work with sync
Change By: Russell Mull
Summary: Add deactivated node timestamp to wire format Make automatic deactivation work with sync

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:11:57 PM4/24/15
to puppe...@googlegroups.com
Russell Mull assigned an issue to Russell Mull
Change By: Russell Mull
Assignee: Russell Mull

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:16:00 PM4/24/15
to puppe...@googlegroups.com
Russell Mull updated an issue
Make automatic expiration work with sync
Change By: Russell Mull
Summary: Make automatic  deactivation  expiration  work with sync

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:16:10 PM4/24/15
to puppe...@googlegroups.com
Russell Mull updated an issue
Currently the deactivated node field is just a boolean. This doesn't work well in an HA/Replicated world. Instead if we include a timestamp Automatic expiration  ( from the puppet master), so the date can be replicated. née

Russell Mull (JIRA)

unread,
Apr 24, 2015, 6:17:59 PM4/24/15
to puppe...@googlegroups.com
Russell Mull updated an issue
Automatic Our current node  expiration  system  (née  automatic deactivation) is problematic when synchronizing PDBs with each other, since it's based on clock comparison. 

Steve Barlow (JIRA)

unread,
May 6, 2015, 11:08:14 AM5/6/15
to puppe...@googlegroups.com
Steve Barlow updated an issue
Change By: Steve Barlow
Sprint: PuppetDB 2015-05-06 , PuppetDB 2015-05-20

Russell Mull (JIRA)

unread,
May 6, 2015, 5:13:57 PM5/6/15
to puppe...@googlegroups.com
Russell Mull assigned an issue to Russell Mull
Change By: Russell Mull
Assignee: Russell Mull

Russell Mull (JIRA)

unread,
May 11, 2015, 6:15:22 PM5/11/15
to puppe...@googlegroups.com

John Duarte (JIRA)

unread,
Jun 2, 2015, 6:24:09 PM6/2/15
to puppe...@googlegroups.com
John Duarte updated an issue
Change By: John Duarte
QA Risk Assessment: Medium

John Duarte (JIRA)

unread,
Jun 2, 2015, 6:24:13 PM6/2/15
to puppe...@googlegroups.com
John Duarte updated an issue
Change By: John Duarte
QA Status: Reviewed

Claudia Petty (Jira)

unread,
Jun 21, 2023, 10:56:07 AM6/21/23
to puppe...@googlegroups.com
Claudia Petty updated an issue
Change By: Claudia Petty
Labels: new-feature
This message was sent by Atlassian Jira (v8.20.21#820021-sha1:38274c8)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages