Uploaded image for project: 'PuppetDB'
  1. PuppetDB
  2. PDB-220

Titles containing numbers returned from functions will throw exceptions during report storage

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: PDB 1.5.0
    • Fix Version/s: PDB 2.1.0
    • Component/s: None
    • Labels:
    • Template:
    • Story Points:
      1
    • Sprint:
      20140618 to 20140702

      Description

      During some testing, I saw this error:

      2013-06-07 17:30:53,124 ERROR [command-proc-45] [puppetdb.command] [97b7fe3f-775e-4ced-833c-6a031758aa47] [store report] Fatal error on attempt 0
      java.lang.IllegalArgumentException: ResourceEvent key :resource-title should be String, got 1459
      	at com.puppetlabs.validation$validate_against_model_BANG_.invoke(validation.clj:82)
      	at com.puppetlabs.puppetdb.report$validate_BANG_.invoke(report.clj:42)
      	at com.puppetlabs.puppetdb.command$eval3849$fn__3852$fn__3855.invoke(command.clj:363)
      	at com.puppetlabs.puppetdb.command$eval3849$fn__3852.invoke(command.clj:362)
      	at clojure.lang.MultiFn.invoke(MultiFn.java:167)
      	at com.puppetlabs.puppetdb.command$produce_message_handler$fn__3944.invoke(command.clj:582)
      	at com.puppetlabs.puppetdb.command$wrap_with_discard$fn__3895$fn__3898.invoke(command.clj:490)
      	at com.puppetlabs.puppetdb.command.proxy$java.lang.Object$Callable$f8c5758f.call(Unknown Source)
      	at com.yammer.metrics.core.Timer.time(Timer.java:91)
      	at com.puppetlabs.puppetdb.command$wrap_with_discard$fn__3895.invoke(command.clj:489)
      	at com.puppetlabs.puppetdb.command$wrap_with_exception_handling$fn__3880$fn__3881.invoke(command.clj:443)
      	at com.puppetlabs.puppetdb.command.proxy$java.lang.Object$Callable$f8c5758f.call(Unknown Source)
      	at com.yammer.metrics.core.Timer.time(Timer.java:91)
      	at com.puppetlabs.puppetdb.command$wrap_with_exception_handling$fn__3880.invoke(command.clj:442)
      	at com.puppetlabs.puppetdb.command$wrap_with_command_parser$fn__3890.invoke(command.clj:465)
      	at com.puppetlabs.puppetdb.command$wrap_with_meter$fn__3871.invoke(command.clj:403)
      	at com.puppetlabs.puppetdb.command$wrap_with_thread_name$fn__3903.invoke(command.clj:505)
      	at clamq.jms$jms_consumer$fn__3141.invoke(jms.clj:38)
      	at clamq.jms.proxy$java.lang.Object$MessageListener$ce893c05.onMessage(Unknown Source)
      	at org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:560)
      	at org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:498)
      	at org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:467)
      	at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:325)
      	at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:263)
      	at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1058)
      	at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1050)
      	at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:947)
      	at java.lang.Thread.run(Thread.java:722)
      

      I was using notify during a load test, the code to replicate is simple:

        $a = range('1','2')
        notify { $a: }
      

      Even confirmed in future parser. The odd thing is that:

      notify { 5: }
      

      ... works and so does:

      notify { '7': }
      notify { [3,5]: }
      notify { ['8','9']: }
      

      Probably something to do with the range return data not being stringified, coming from a function? Not sure. But this explains why it hasn't been seen before.

        Attachments

          Activity

            jsd-sla-details-panel

              People

              • Assignee:
                wyatt Wyatt Alt
                Reporter:
                redmine.exporter redmine.exporter
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: