[foreman-dev] Foreman hooks script incompatible issue due to the changes of "Fixes #16114"

2017-02-13 Thread Hirai, Akira
Hello,

I use a foreman hooks script which controlled by the host parameters, but the 
script has not worked since updating foreman from 1.13 to 1.14.

When looking into the code, I found that it's due to "Fixes #16114" on 1.14.0.
JSON representation of the hook object passed in on stdin has not included 
parameters/all_parameters arrays.

[Add parameters to host API response when given include=parameters or 
all_parameters (#16114)]


app/views/api/v2/hosts/show.json.rabl
 
5   -node do |host|
6   -  { :parameters => partial("api/v2/parameters/base", :object => 
host.host_parameters.authorized) }
7   -end
8   -
9   -node do |host|
10  -  { :all_parameters => partial("api/v2/parameters/base", :object => 
host.host_params_objects) }
11  -end


In addition to foreman hooks, host API such as "POST /api/hosts" and "PUT 
/api/hosts/:id" have not returned parameters/all_parameters arrays in JSON 
response since applying this patch.

I suggest to return to show.json.rabl back to the original. I think that the 
restoration of show.json.rabl does not affect the other API's JSON response 
such as "GET /api/hosts" or "GET /api/hosts/:id".

Does it have any problems or affect any APIs/Plugins?
If so, I will propose an alternative patch for foreman hooks to revive missing 
arrays.

Regards,
Akira Hirai

-- 
You received this message because you are subscribed to the Google Groups 
"foreman-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to foreman-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [foreman-dev] Plan for dropping Puppet 3 in the installer modules

2017-02-13 Thread Ewoud Kohl van Wijngaarden
http://projects.theforeman.org/issues/18471 is now open to track this.

On Tue, Jan 24, 2017 at 05:27:25PM +0100, Ewoud Kohl van Wijngaarden wrote:
> Not at the moment. As far as I know this is the first effort to
> determine what should be done.
> 
> On Tue, Jan 24, 2017 at 09:31:10AM -0500, Eric D Helms wrote:
> > Is there a Redmine issue or tracker related to dropping Puppet 3 support
> > that we can reference?
> > 
> > On Mon, Jan 23, 2017 at 8:30 AM, Ewoud Kohl van Wijngaarden <
> > ew...@kohlvanwijngaarden.nl> wrote:
> > 
> > > Hello all,
> > >
> > > We should come up with a plan for dropping Puppet 3 in our installer
> > > modules.
> > >
> > > Officially Puppet 3 is already EOL since 1-1-2017. We also know that
> > > both puppetlabs and voxpupuli (our only dependencies) are dropping
> > > Puppet 3 support.
> > >
> > > That said we also know that many of our users are still on Puppet 3 and
> > > upgrading is hard for many.
> > >
> > > My proposal is to deprecate using our modules with 1.15 and drop it in
> > > master for 1.16. We can still keep Puppet 3 branches but they are on a
> > > best-effort basis and no backwards incompatible changes.
> > >
> > > Thoughts on this?

-- 
You received this message because you are subscribed to the Google Groups 
"foreman-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to foreman-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.