Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix more providers #1062

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Kidswiss
Copy link

@Kidswiss Kidswiss commented Nov 28, 2019

In #1036 you fixed the autoload issue for some provider types. While testing today I found that there were still some providers that can fail to autoload.

How to reproduce:

  • Use puppet-elasticsearch 6.4.0
  • Restart puppetmaster
  • Run puppet on an agent

Result:

Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user: Could not autoload puppet/provider/elasticsearch_user/users: no such file to load -- puppet/provider/elastic_user_command (file: /etc/puppetlabs/code/modules/elasticsearch/manifests/init.pp, line: 554, column: 3) on node agent1.vagrant.test
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

Applying the same fix as in #1036 to these types/providers fixed the issue.

Maybe it would make sense to change the imports for all the types/providers?

Pull request acceptance prerequisites:

  • Signed the CLA (if not already signed)
  • Rebased/up-to-date with base branch
  • Tests pass
  • Updated CHANGELOG.md with patch notes (if necessary)
  • Updated CONTRIBUTORS (if attribution is requested)

@elasticmachine
Copy link

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

@cla-checker-service
Copy link

Author of the following commits did not sign a Contributor Agreement:
0156185

Please, read and sign the above mentioned agreement if you want to contribute to this project

@abaddononion
Copy link

I would like to weigh in and confirm that we're encountering this issue as well, and need this PR to get resolved somehow.

root@lvlslogp01:~$ puppet agent --test
Info: Certificate revocation is disabled, skipping CRL download
Info: Using configured environment 'production'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Retrieving locales
Info: Loading facts
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user_file: Could not autoload puppet/provider/elasticsearch_user_file/oss_xpack: no such file to load -- puppet/provider/elastic_parsedfile (file: /etc/puppetlabs/code/environments/production/community-modules/elasticsearch/manifests/init.pp, line: 567, column: 6) on node lvlslogp01.lightningsource.com
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

It can clear after subsequent runs, but this can be a major problem when you've enabled max-requests-per-instance to combat memory leaks in other modules.

@fatmcgav
Copy link
Contributor

fatmcgav commented Feb 4, 2020

Hi there,

Firstly, thank you for taking the time to contribute, and apologies for the radio silence from Elastic on this PR.

I'm going to be working on this module over the next few weeks, with an ultimate aim of updating the module to support the elasticsearch 7.x and simplifying the module to make it easier to use.

I'll be reviewing all the open issues and PRs over the next few days, and will merge or provide feedback where appropriate.

So please hang in there whilst we give this module some TLC.

Thanks again.

Copy link
Contributor

@fatmcgav fatmcgav left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

@fatmcgav
Copy link
Contributor

fatmcgav commented Feb 4, 2020

@Kidswiss The changes look sensible.

Would you be able to sign the CLA as noted in #1062 (comment)?

@fatmcgav fatmcgav added the bug Something isn't working label Feb 4, 2020
@crigertg
Copy link

Running octocatalog-diff causes similar issues:

Error: Could not autoload puppet/provider/elasticsearch_user_file/shield: cannot load such file -- puppet/provider/elastic_parsedfile
Error: Could not autoload puppet/type/elasticsearch_user_file: Could not autoload puppet/provider/elasticsearch_user_file/shield: cannot load such file -- puppet/provider/elastic_parsedfile
Error: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user_file: Could not autoload puppet/provider/elasticsearch_user_file/shield: cannot load such file -- puppet/provider/elastic_parsedfile (file: /tmp/ocd-ipc-20200310-16487-i2apg8/ocd-builddir-20200310-16602-1krbujk/environments/production/modules/elasticsearch/manifests/init.pp, line: 567, column: 6) on node test.es.local
Error: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user_file: Could not autoload puppet/provider/elasticsearch_user_file/shield: cannot load such file -- puppet/provider/elastic_parsedfile (file: /tmp/ocd-ipc-20200310-16487-i2apg8/ocd-builddir-20200310-16602-1krbujk/environments/production/modules/elasticsearch/manifests/init.pp, line: 567, column: 6) on node test.es.local
Error: Failed to compile catalog for node test.es.local: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user_file: Could not autoload puppet/provider/elasticsearch_user_file/shield: cannot load such file -- puppet/provider/elastic_parsedfile (file: /tmp/ocd-ipc-20200310-16487-i2apg8/ocd-builddir-20200310-16602-1krbujk/environments/production/modules/elasticsearch/manifests/init.pp, line: 567, column: 6) on node test.es.local

I was not able to fix the issue in about 1 hour and decided to wait if this gets fixed due to the changes in the upcoming release. But I'll be happy to help if i can get a understanding what changes are planned for the whole lib layout in this module.

@vox-pupuli-tasks
Copy link

Dear @Kidswiss, thanks for the PR!

This is Vox Pupuli Tasks, your friendly Vox Pupuli Github Bot. I noticed that your pull request has CI failures. Can you please have a look at the failing CI jobs?
If you need any help, you can reach out to us on our IRC channel voxpupuli on Freenode or our Slack channel voxpupuli at slack.puppet.com.
You can find my sourcecode at voxpupuli/vox-pupuli-tasks

@vox-pupuli-tasks
Copy link

Dear @Kidswiss, thanks for the PR!

This is Vox Pupuli Tasks, your friendly Vox Pupuli GitHub Bot. I noticed that your pull request contains merge conflict. Can you please rebase?

You can find my sourcecode at voxpupuli/vox-pupuli-tasks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants