tendomart
(tendo kiiza Martyn)
May 11, 2020, 5:33am
1
Hello Team , has anyone experienced such an ERROR while Using Generic DAO and Service Methods to upgrade Fhir Data Access Objects and Service ?
I suspect there could be typo for the DiagnosticReport Resource
This is my Updated FhirDiagnosticReportDaoImpl
and Updated FhirDiagnosticReportServiceImpl
Thoughts @ibacher @jecihjoy @gcliff @sharif
gcliff
(CLIFF GITA)
May 11, 2020, 6:07am
2
@tendomart you can remove this code snippet from your ```
FhirDiagnosticReportDaoImpl
and compile again,hope your
FhirDiagnosticReportDao
is extending FhirDao
to
> */
> private static final long serialVersionUID = 1L;
>
> @Autowired
> @Qualifier("sessionFactory")
> SessionFactory sessionFactory;
>
> @Override
> public Obs getObsGroupByUuid(String uuid) {
> return (Obs) sessionFactory.getCurrentSession().createCriteria(Obs.class).createAlias("groupMembers", "group")
> .add(eq("uuid", uuid)).uniqueResult();
> }
1 Like
tendomart
(tendo kiiza Martyn)
May 11, 2020, 6:19am
3
Thanks @gcliff , but actually I tried that earlier without much success ,actually run into other issues, donāt you think this entails totally unimplementing FhirDiagnosticReportDao ?
I suspect there are conflcts ,since is mapped differently , but much more there is collision with the **BaseFhirDao**
Class and the sub-class **FhirDiagnosticReportDaoImpl**
gcliff
(CLIFF GITA)
May 11, 2020, 6:27am
4
thanks for the feedback though i dont think so because
FhirDiagnosticReportDaoImpl
must implement
FhirDiagnosticReportDao
as part of the contract
,kindly share your pr for a deeper look into this
gcliff
(CLIFF GITA)
May 11, 2020, 6:53am
5
@tendomart when you remove the code snippet to,you will need to use getSessionFactory().getCurrentSession()
instead of sessionFactory.getCurrentSession()
in your
saveObsGroup(Obs obs)
method
tendomart
(tendo kiiza Martyn)
May 11, 2020, 7:09am
6
ok Let me check that.
@gcliff
openmrs:master
ā tendomart:master
opened 07:03AM - 11 May 20 UTC
(WIP) Update DiagnosticReport DAO and Service
https://issues.openmrs.org/browā¦ se/FM2-151
Can you please look into this
@ibacher @gitcliff
gcliff
(CLIFF GITA)
May 11, 2020, 7:16am
7
i have added a comment on github
sharif
(Sharif Magembe)
May 11, 2020, 7:57am
8
Thanks @gcliff for taking this , i have added a comment on github
reagan
(Reagan patrick Makoba)
May 11, 2020, 8:23am
9
@tendomart To add on what @gcliff has advised thus far, you may want to look at a similar pattern here to see how to access the sessionfactoryā¦
reagan
(Reagan patrick Makoba)
May 11, 2020, 8:25am
10
And for record I canāt seem to see the error logs you have shared via hastebin.com ā¦ I checked the ones of travisā¦Could you use pastebin maybe.
1 Like
tendomart
(tendo kiiza Martyn)
May 11, 2020, 8:43am
11
Sorry @reagan i think hastebin link has issues, you may grab it at [INFO] Fail to format: 0 file(s)[INFO] Skipped: - Pastebin.com
Thanks @sharif @gcliff for the feed , iāll keep you posted of the progress.
2 Likes