phabricator: model: Reference the forge's instance name in model

As phabricator is an "instance" lister (there exists multiple instances of
phabricator in the wild), we need to reference that information.

In effect, this aligns phabricator lister with for example the gitlab one.

Related T1801
Related P434
This commit is contained in:
Antoine R. Dumont (@ardumont) 2019-06-18 07:06:48 +02:00
parent fc92c79b7e
commit af681ac128
No known key found for this signature in database
GPG key ID: 52E2E9840D10C3B8
2 changed files with 3 additions and 1 deletions

View file

@ -84,7 +84,8 @@ class PhabricatorLister(SWHIndexingHttpLister):
'html_url': url,
'origin_url': url,
'description': None,
'origin_type': repo['fields']['vcs']
'origin_type': repo['fields']['vcs'],
'instance': self.instance,
}
def get_next_target_from_response(self, response):

View file

@ -13,3 +13,4 @@ class PhabricatorModel(IndexingModelBase):
uid = Column(String, primary_key=True)
indexable = Column(Integer, index=True)
instance = Column(String, index=True)