Entries filed under: General News

Back to Index

Announcing PuppetDB 1.1: Do More With Your Data

Posted on
By
Chris Price
in
Blog, General News, Open Source, product release
Responses
0 Comments

PuppetDB is the next-generation open source storage service for Puppet-produced data. With the initial 1.0 release in September 2012, it provided a high-performance system for capturing all of the catalogs and facts for your Puppet nodes. It could be used as a drop-in replacement for the Puppet inventory service, and for the first time gave users a fast and scalable way to take advantage of Puppet storeconfigs and exported resources.

But you already know all of that, because you’re already using and loving PuppetDB, right? On the off chance that you’re not, take a peek at the “Learn More” section at the end of this document. There you’ll find links to an introductory video, blog post, and other info about getting started with PuppetDB.

Today we’re excited to announce the next major release of PuppetDB: version 1.1. There are quite a few new features, but the main theme is to empower you to do even more with your Puppet data. To that end, we’ve exposed a much more robust query API. We’ve also provided some more user-friendly HTTP routes, improved performance, and introduced experimental storage for Puppet reports. We think you’re going to love these new features, so, without further ado, let’s have a look at each of them in a bit more detail!

What’s New in PuppetDB 1.1

Enhanced Query API

Version 1.0 introduced an HTTP query API that would allow you to search through your catalog and fact data from anywhere you like. Its main purpose was to allow us to provide a drop-in replacement for storeconfigs and the inventory service, but we’ve always aimed for it to offer much more than that. We’re storing all of this great data about your Puppet node population, and we want to absolutely maximize your ability to query it in any way that is useful to you! PuppetDB 1.1 makes a big leap forward on that front.

The HTTP query API is now versioned, so all of the PuppetDB query URLs should now be prefixed with a version string; for example: http://localhost:8080/v1/facts. The new, enhanced versions of the various queries are available under the new /v2 endpoints, but the original versions are still accessible under /v1. (Accessing the query endpoints with a URL that does not contain a version number is considered deprecated, but will currently route you to the /v1 endpoints.)

Improved Fact Query

In PuppetDB 1.0, the facts endpoint could only be used to retrieve the set of facts for a given node. In 1.1, the new /v2/facts endpoint supports a full query language, similar to the one supported by the resources endpoint. So, for example, you can now issue a query like this:

  ["and",
    ["=", "name", "operatingsystem"],
    ["=", "value", "Debian"]]

 

which will return all of the operatingsystem facts for all of your Debian nodes. For more info, check out the v2 fact query documentation.

Subqueries

One of the most powerful features of PuppetDB 1.1 is the introduction of a subquery operator. This basically allows you to “join” two queries together; so you are able to, for example, construct a single query that considers both facts and resources. This gives you the ability to answer a question like “what are all of the IP addresses of the nodes that have class ‘Apache’?” Without subqueries, if you wanted to get this data, you’d need to execute a resource query to find all of the nodes, and then execute a fact query for each of the nodes to get the IP addresses. Now you can do it all in one shot!

Here’s what that query against /v2/facts might look like:

["and"
 ["=" "name" "ipaddress"]
 ["in" "certname"
  ["extract" "certname"
   ["select-resources"
    ["and"
     ["=" "type" "Class"]
     ["=" "title" "Apache"]]]]]]

 

which might yield some results like this:

[ {
 "certname" : "foo.example.com",
 "name" : "ipaddress",
 "value" : "192.168.100.102"
}, {
 "certname" : "bar.example.com",
 "name" : "ipaddress",
 "value" : "192.168.100.103"
} ]

 

The subquery syntax can be a bit tricky at first, but it opens the door for building some very expressive queries. The most common use case will be to join fact and resource queries, but it is also possible to do resource-resource subqueries, fact-fact subqueries, or even nest subqueries. For more info, check out our query API tutorial, the documentation on query operators, or the documentation for the resource and fact query endpoints.

Regular Expressions

Sometimes an admin just needs to find all of their /foo.*/ nodes, right? The v2 query endpoints add support for a regular expression operator: "~". This means that you can now do a fact query like this:

  ["and", ["=", "name", "ipaddress"], ["~", "certname", "foo.*"]]

 

And, voila, you’ll have all of the IP addresses for all of your nodes whose names begin with foo. (You can use this operator in other queries besides fact queries as well.)

Improved Node Query

In previous releases of PuppetDB, the node query endpoint only returned a list of node names. If you ran a node query to find some nodes that matched a certain set of conditions, and you wanted to get some additional status info about those nodes, you’d need to submit some additional follow-up queries to the status endpoint. In v2, all node queries return data that looks like this:

[ {
 "name" : "foo.mydomain.net",
 "deactivated" : null,
 "catalog_timestamp" : "2013-01-08T23:43:24.330Z",
 "facts_timestamp" : "2013-01-08T23:43:12.580Z",
 "report_timestamp" : "2013-01-08T23:43:50.000Z"
}, {
 "name" : "bar.mydomain.net",
 "deactivated" : null,
 "catalog_timestamp" : "2013-01-08T23:38:21.099Z",
 "facts_timestamp" : "2013-01-08T23:38:07.280Z",
 "report_timestamp" : "2013-01-08T23:38:37.000Z"
} ]

 

This should be more useful for tasks such as monitoring.

RESTful Query Routes

Most of the v2 query endpoints now support adding additional path elements to the URI, to provide a slightly more intuitive way of expressing common queries (rather than using the somewhat more verbose query parameter syntax). So, for example, if you wanted to get all of the operatingsystem facts for all of your nodes, you could do it this way (ignoring URL encoding issues for simplicity):

  /v2/facts?query=["=", "name", "operatingsystem"]

 

But in PuppetDB 1.1, you can now also use this shorthand:

  /v2/facts/operatingsystem

 

You can still pass the query argument when using these new friendlier endpoints, so you are still able to leverage the full power of the query API:

  /v2/facts/operatingsystem?query=["=", "certname", "foo.localdomain"]

 

Here are some other examples of the new, friendlier query URLs:

  /v2/facts/operatingsystem/Debian : Find all facts named "operatingsystem" whose value is "Debian" across all nodes
  
  /v2/resources/Package : Find all resources of type "Package" across all nodes
  
  /v2/resources/Package/postgresql : Find all resources of type "Package", with title "postgresql", across all nodes  
  
  /v2/nodes/foo.localdomain : Find the node named "foo.localdomain"

  /v2/nodes/foo.localdomain/facts : Return all facts for the node named "foo.localdomain"
  
  /v2/nodes/foo.localdomain/resources : Return all resources for the node named "foo.localdomain"

 

(This is not an exhaustive list. For complete documentation see the node, facts, and resources query documentation pages.)

Experimental Storage

One of the most frequently requested features for PuppetDB has been for us to allow storage and querying of Puppet report data. With PuppetDB 1.1, we’ve taken our first big step towards providing this functionality. We don’t yet support any advanced querying of reports, but by simply adding the puppetdb report processor to your Puppet master’s configuration, you can store all of your report data in PuppetDB and access it via a simple HTTP retrieval API. When this feature is enabled, the latest seven days worth of reports will be stored. This time period is configurable, so that you can make your own decision about the right balance between disk usage and how much history you’d like to retain.

So, why “experimental”? Basically, we recognize that the current API for “querying” reports is not complete enough to do a lot of the things that users will want to do with it. (It really is just a “retrieval” API at this point.) However, since the report storage code was ready to go–and provides some value even without a robust query API–we didn’t want to miss the opportunity to go ahead and get it into the hands of users. It will also give you a chance to kick the tires a bit and get a feel for what is coming down the road, in case you have any suggestions or input on the direction we’re heading with it.

For more information about enabling report storage, see the Puppet master configuration documentation; for more info about the HTTP retrieval API, see the docs for the experimental reports and events query endpoints.

Improved Performance

We’ve made a few tweaks under the hood relating to how we de-duplicate catalogs and cache data about them. In our testing, we’ve seen a significant decrease in the amount of time that it takes to “warm up” the cache and store the first catalogs for each node after a restart. We’ve also noticed some improvement to the performance of catalog storage overall. Your mileage may vary depending on what your catalogs look like, but hey, faster is better, right?

What’s Next?

We’re working hard to keep cranking out new features and make sure that you consider PuppetDB to be an indispensable part of your Puppet ecosystem. Here are a few things that you can expect to see in the not-too-distant future:

  • Improved report query capabilities: we know that we haven’t yet scratched the surface of what users would like to be able to do with reports, so expect to see drastic expansion of the report query API in a future release.
  • PuppetDB bundled with Puppet Enterprise: we intend to deliver an absolutely seamless, dead-simple, out-of-the-box experience for leveraging the power of PuppetDB in Puppet Enterprise environments.
  • Capture data about Puppet modules: in an upcoming release of Puppet core, we’ll be adding more information to catalogs about what module (if any) each class or resource was defined in. We’ll also capture that data in PuppetDB, and extend the query API to allow you to include module information in your queries.

Tell Us What You Think!

We think that PuppetDB is really cool. But at the end of the day, it’s not what we think that keeps the lights on over here at Puppet Labs — it’s what you think. So, if you have an opinion on any of our current features or suggestions to help us shape and prioritize features for upcoming releases, we really want to hear from you! Here are some great ways to get in touch with us:

  • Sign up to be a Puppet Test Pilot! You’ll get free goodies as a reward for your participation if you are able to volunteer a few minutes of your time to tell us what you think about prototypes of upcoming features. We did a lot of user testing around the new query API prior to this release, and we hope to do a lot more in the future. The upcoming reports query API is a likely candidate for this!
  • Ping us on IRC: we’re usually online in #puppet on freenode. Just mention ‘puppetdb’ and you’re pretty likely to get a quick response.
  • Send an e-mail to the puppet-users or puppet-dev mailing lists.

Learn More

Here are some good resources for learning about and getting started with PuppetDB:

Looking Back at DevOps December

Posted on
By
michelle
in
Blog, Community, DevOps, DevOps December, General News
Responses
0 Comments

Over the last month, we brought together nine DevOps blog posts from guest authors and Puppet Labs employees—covering the spectrum from development, SQA, and operations. These posts came in the form of technical tutorials, thought pieces, case studies, podcasts, and comics. We want to thank every one of our contributors for helping us end a great year, and setting the tone for a collaborative 2013.

James Turnbull, Has DevOps Made a Difference?

James looks at some of the data around DevOps jobs, the hype around the movement, and asks the big questions:

Some have argued DevOps jumped the shark when the first analyst added it to their portfolio. Whatever side of the argument you fell on, the DevOps movement provoked a lot of discussion about the future of IT management. But has DevOps resulted in changes in the culture and processes of IT organisations? Has DevOps become another silo in your organisation? Or are you still asking “What the hell is DevOps?”

Read the rest of this entry »

Has DevOps Made a Difference?

Posted on
By
James Turnbull
in
Blog, Community, DevOps, DevOps December, General News
Responses
1 Comment »

DevOps emerged in 2009 and over the last three years it has gained considerable momentum, albeit some of it contradictory, in the IT industry. Some loved it. Some lived it. Others changed their job title and moved on. Many hated it. Some have argued DevOps jumped the shark when the first analyst added it to their portfolio. Whatever side of the argument you fell on, the DevOps movement provoked a lot of discussion about the future of IT management. But has DevOps resulted in changes in the culture and processes of IT organisations? Has DevOps become another silo in your organisation? Or are you still asking “What the hell is DevOps?”

Read the rest of this entry »

Take the 2012 DevOps Survey

Posted on
By
James Turnbull
in
Blog, Community, DevOps, DevOps December, General News
Responses
0 Comments

2012-devops-survey

We’re excited to announce our second annual DevOps Survey, in conjunction with IT Revolution Press. Our last survey saw over 700 respondents and showed us how DevOps has evolved since the term was first coined in 2009 by Patrick Debois. A lot has changed in the last 18 months, and we want to know how DevOps has affected you and your organization.

The survey was developed by Puppet Labs and reviewed by Gene Kim and Jez Humble. This year, we’ve expanded the survey to include performance metrics to benchmark performance across organizations. Topics include:

  • Demographic and salary data
  • Performance metrics
  • Benefits and barriers
  • Staffing
  • Tools
  • Community

The survey should take about 10 minutes, and you’ll be entered to win PuppetConf 2013 tickets, a copy of Gene Kim’s upcoming book, The Phoenix Project: A Novel About IT, DevOps, and Helping Your Business Win, and Puppet Labs t-shirts. You’ll also receive the survey results so you can benchmark your organization against your peers.

Please help us spread the word about the survey so we can get a complete picture of the state of DevOps today.

Thanks for participating! We look forward to sharing the results in early 2013.

Puppet and New Relic, Now on the Puppet Forge

Posted on
By
James Turnbull
in
Blog, Community, Company, General News, Module of the Week, Modules
Responses
1 Comment »

One of the things I’ve always found amusing about Operations is that people think we spend all of our time fixing broken things. It’s true to some extent: something breaks, we fix it. But the most challenging issues in Operations aren’t that simple binary break/fix. The really interesting issues are performance issues, intermittent bugs, and transitory problems: “it’s a little slow” or “something is off” or the “it’s not quite right” issues. Not only are those problems really challenging, but they can also really interesting (and often fun) to solve.

Diagnosing and solving those problems, however, is very different from dealing with break/fix issues. You still need good diagnosis skills to deal with break/fix issues, but you are usually able to rely on the change-test-validate cycle: make a change, test it fixes the issue, and then validate you haven’t broken anything else. With less binary problems, you sometimes don’t even know where to start or are working from unsubstantive qualitative feedback: “Something doesn’t feel right.”

Operations Loves Data

Read the rest of this entry »

Building Foundations for Disaster Recovery

Posted on
By
Mike Stahnke
in
Blog, Community, Disaster Recovery, General News, Systems Management, Tips
Responses
1 Comment »

In the wake of recent events on the East Coast of the United States, disaster recovery (DR) planning has reared its head again. Of course, it’s a bad time to think about disaster recovery right after an event with such a large impact. However, it’s even worse to never think about it.

Prior to working at Puppet Labs, I spent a lot of time on disaster recovery. For nearly two years, I led a team designing multi-site replication, creating reference architectures for availability and recovery, and selling our business partners on disaster recovery investments. This was for one of the top performing business units at a Fortune 100 company with seven and eight figure budgets for DR.

Disaster recovery is a huge proposition. It’s costly, time consuming, difficult to test correctly and often the first thing cut when doing budget reviews. DR planning is also never complete. You evolve. You change. Your plans need to as well.

The starting points for DR planning can be difficult to find. Infrastructure engineers often jump to technical solutions. Before you figure out the newest wizbang in storage replication technologies and failover, take a step back.

Read the rest of this entry »

Puppet Forge: Over 600 Modules and We’re Just Getting Started

Posted on
By
Ryan Coleman
in
Blog, General News, Modules
Responses
3 Comments »

Today, we’re excited to announce that we’ve released a major update to the Puppet Forge that will help us maintain momentum with the enormous growth in the last six months. The user community has doubled in size alongside the number of modules and download volume. This most recent release is focused on refining our platform to scale appropriately with growth, provide more useful information about modules, and prepare the team to release great new features faster than ever.

The Visual Refresh

While today’s release was primarily focused on rebuilding our platform, we managed to get several improvements into the front-end.

If you’re a frequent visitor to the Puppet Forge, the first thing you’ll notice today is a cleaner, simplified front page. The changes reflect a desire to offer more room to report the recent activity of our large and growing community. In the near future, you can expect to find even more informational features added to keep you up-to-date with activity on the Puppet Forge.

On the individual module pages, you’ll notice a number of tweaks and enhancements, particularly the Puppet Module Tool installation instructions. One of our priorities is to further enhance module pages to include relevant information that will help you determine which module is best for you to use on your systems.

Brand New Data & Web Services

The previous Puppet Forge was a single web application that contained the website you visited, the data within it, and the API used by tools like the Puppet Module Tool and Gepetto. Considering our future needs for growth and flexibility, we chose to split these pieces apart and enhance them in the process.

The Puppet Forge you see today is composed of multiple services, which include the web service you’re browsing to and our new API service which stores data consumable by the web service and other tools. Everything that the previous Forge allowed as an API has been ported to the new Forge and referred to as the v1 API. The v2 API service is still being finalized but when we release it, you can write your own tools to interact with Puppet Forge modules, download them and even publish new ones.

Puppet Management Fairy Dust!

Previously, the Puppet Forge was run on a single box with a sqlite database (yeah, we know!). Along with the service split mentioned above (including a move from sqlite to postgres), the Puppet Forge is positioned to be highly scalable with Puppet. Our Operations Team really kicked ass with this deployment, utilizing Puppet to make their jobs easier while allowing the Puppet Forge to scale quickly and predictably.

There’s a lot of Puppet fairy dust involved in making this release possible, but some of the highlights are available on the Puppet Forge. To reliably manage network configuration between our disparate services, Adrien Thebo wrote and published his network module. Each open port needed appropriate firewall rules in place, provided courtesy of the Puppet Labs firewall module. They chose the Puppet Labs postgresql module (previously owned and maintained by Kenn Knowles at Inkling) to build, configure and maintain the database service. Lots more Puppet goodness was created to make this happen. Expect more to be published by our operations team in the future.

What’s Next?

The Puppet Forge has seen enormous growth recently, and the newly formed team is ramping up to respond with features that help you succeed with Puppet and Puppet Enterprise.

Now that this release is out the door, our immediate focus is on simplifying the process for publishing content to Forge, making it easier and more natural to your workflow. Expect the ability to publish through various programmatic methods, including the CLI, very soon. Along with vast improvements to content publishing, we’re eager to arm you with great tools to help guide you when picking Puppet modules that will help you grow your business. Expect better documentation on modules, information on module popularity, style guide compliance information, and more.

As we build these features, we constantly validate that we’re building the right tool. One of our strongest methods is you! Become a Puppet Test Pilot for an opportunity to help us test our latest creations and receive some swag along the way. Additionally, we love to receive feedback in our issue tracker. You’re also welcome to send your thoughts straight at me via ryan@puppetlabs.com or via @ryanycoleman on Twitter.

Thank you so much for being a part of the Puppet community. Please check out the Puppet Forge now, publish one of your modules and tell us what you think!

Learn More

Puppet Labs and OpenStack: Summit schedule, modules, and joining the community

Posted on
By
michelle
in
Blog, Cloud, Community, Conferences and Workshops, General News, Modules
Responses
0 Comments

We’re excited to be at the OpenStack Summit in San Diego next week. Dan Bode and Teyo Tyree will be hanging out at Cisco’s booth, ready to talk Puppet, OpenStack, community, and anything else you might want to have a conversation about. Dan will also be taking part in a number of scheduled talks:

Read the rest of this entry »

Watch and Learn: PuppetConf 2012 videos

Posted on
By
Kara Sowles
in
Blog, Community, Conferences and Workshops, DevOps, General News, PuppetConf
Responses
1 Comment »

We’re proud to present the 67 recorded presentations from PuppetConf 2012, along with the official photos on our Flickr account. There’s something for everyone in the PuppetConf talks, with speakers from EMC, PayPal, Splunk, VMware, Pinterest, and many others. Not ready to choose? We’ve picked out a few for you to start off with:

Read the rest of this entry »

Can’t Make it to PuppetConf? Watch the Live Video Stream

Posted on
By
michelle
in
Blog, Community, DevOps, General News, PuppetConf, Tips
Responses
0 Comments

PuppetConf 2012 is 3 days away! While we wish everyone could make it, we know it’s not always possible to get the time off work. In an effort to provide VIP access, we’ll be streaming live video of the two main rooms, thanks to our streaming sponsor and provider Ooyala.

Sign up for live video streaming

Read the rest of this entry »