This question was already answered by Randy Barlow. It seems that the directory loading method has been deprecated. I’ve since started using the method suggested. Here is Randy’s response.
Hello Jay, The directory loading plugin discovery method has been deprecated for some time, and will likely be removed with Pulp 3.0. I recommend using the Python entry points plugin loading method instead, which is how all Pulp plugins get loaded. Here's how the Python plugin announces its presence to Pulp: https://github.com/pulp/pulp_python/blob/pulp-python-1.1.1-1/plugins/setup.py#L15-L28 I hope that helps! -- Randy Barlow irc: bowlofeggs *From:* Mihai Ibanescu [mailto:mihai.ibane...@gmail.com] *Sent:* Wednesday, May 25, 2016 8:50 AM *To:* Jay Medrano <jay.medr...@neulion.com> *Cc:* pulp-list <Pulp-list@redhat.com> *Subject:* Re: [Pulp-list] Implementing Support for New Types - Directory Loading Did you run pulp-manage-db? sudo -u apache pulp-manage-db On Fri, May 20, 2016 at 11:03 AM, Jay Medrano <jay.medr...@neulion.com> wrote: Hello folks, I’m trying to add support for a new type <http://pulp.readthedocs.io/en/2.7-release/dev-guide/newtypesupport/plugin/common.html#plugin-directory>, and I’m using the “directory loading” method and I’m placing files directly under /usr/lib/pulp/plugins for testing. The problem is I can’t seem to get Pulp to recognize my new importer. This is what my importer directory looks like. *my_importer/* *|-- importer.py* *`-- __init__.py* I’ve got some really basic code in my importer.py file and I’ve already added a types definition under /usr/lib/pulp/plugins/types followed by a ‘sudo -u apache pulp-manage-db’ call. *from pulp.plugins.importer import Importer* *def entry_point():* * return MyContentImporter, {}* *class MyContentImporter(Importer):* * @classmethod* * def metadata(cls):* * return {* * 'id' : 'my_importer',* * 'display_name' : 'My Artifact',* * 'types' : ['my_artifact'],* * }* * def validate_config(self, repo, config):* * return True, ''* This is the error I’m getting. *2016-05-20 10:41:17,476 - ERROR - Exception occurred:* * href: /pulp/api/v2/repositories/* * method: POST* * status: 400* * error: The importer type my_importer does not exist* * traceback: None* * data: {u'args': [], u'error': {u'code': u'PLP1008', u'data': {u'importer_type_id': u'my_importer'}, u'description': u'The importer type my_importer does not exist', u'sub_errors': []}}* Any help to get my importer to be recognized would be greatly appreciated. Thanks, Jay _______________________________________________ Pulp-list mailing list Pulp-list@redhat.com https://www.redhat.com/mailman/listinfo/pulp-list
_______________________________________________ Pulp-list mailing list Pulp-list@redhat.com https://www.redhat.com/mailman/listinfo/pulp-list