Re: [Dhis2-devs] Tracked Entity Instances Query - SQL syntax error

2016-08-23 Thread Pamod Amarakoon
Hi Morten,

Just wondering whether this has been fixed.

Thank you

On Wed, Aug 17, 2016 at 7:24 PM, Pamod Amarakoon  wrote:

> Thank you Morten.
>
> On Wed, Aug 17, 2016 at 7:10 PM, Morten Olav Hansen 
> wrote:
>
>> Seems like a bug yes, I will look into it
>>
>> --
>> Morten Olav Hansen
>> Senior Engineer, DHIS 2
>> University of Oslo
>> http://www.dhis2.org
>>
>> On Mon, Aug 15, 2016 at 10:34 AM, chathura widanage <
>> chathurawidan...@gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> I am using below API call to query all the TEIs which are accessible by
>>> the current user.
>>>
>>> /api/trackedEntityInstances/query.json?ouMode=ACCESSIBLE
>>> ribute=izuwkaOUgFg=C8DBAo2wEYN=BZEpuufLy
>>> DE=WqdldQpOIxm
>>>
>>> In our setup,  we have 5 orgUnitLevels and above query works fine for
>>> superuser who has just one orgUnit assigned which is of level 1.
>>>
>>> There are other users who has multiple level 4 and 5 orgUnits assigned.
>>> Above API call fails for those users giving a 500 error code. Basically
>>> this doesn't work for any user who has multiple orgUnits.
>>>
>>> The cause for the issue seems to be a SQL syntax error.
>>>
>>> Please find the link to the stack trace below.
>>>
>>> https://dl.dropboxusercontent.com/u/81780569/stack.txt
>>>
>>> The issue was visible in DHIS2 v2.23 and v2.24.
>>>
>>> Have I done something wrong in the above API call or is this a bug in
>>> the DHIS2. Is there any walk around for this issue?
>>>
>>> Thanks
>>> --
>>> Best Regards,
>>>
>>> *Chathura Widanage,*
>>> Undergraduate,
>>> Department of Computer Science and Engineering,
>>> University of Moratuwa,
>>> Sri Lanka
>>>
>>> 
>>>   
>>> 
>>> 
>>>
>>> ___
>>> Mailing list: https://launchpad.net/~dhis2-devs
>>> Post to : dhis2-devs@lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-devs@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Regards,
> Pamod Amarakoon
>
> Confidentiality Notice: the information contained in this email and any
> attachments may be legally privileged and confidential. If you are not an
> intended recipient, you are hereby notified that any dissemination,
> distribution, or copying of this e-mail is strictly prohibited. If you have
> received this e-mail in error, please notify the sender and permanently
> delete the e-mail and any attachments immediately. You should not retain,
> copy or use this e-mail or any attachments for any purpose, nor disclose
> all or any part of the contents to any other person.
>
>
>
>


-- 
Regards,
Pamod Amarakoon

Confidentiality Notice: the information contained in this email and any
attachments may be legally privileged and confidential. If you are not an
intended recipient, you are hereby notified that any dissemination,
distribution, or copying of this e-mail is strictly prohibited. If you have
received this e-mail in error, please notify the sender and permanently
delete the e-mail and any attachments immediately. You should not retain,
copy or use this e-mail or any attachments for any purpose, nor disclose
all or any part of the contents to any other person.
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] Dataelement not loading in dataelement group

2016-08-23 Thread Guy Ekani
Hello Team,
Please how many dataelements could we load in datalement group window? 
because in our case we have about 3.000 and it's not loading in DHIS 2.23, but 
was previously loading well in Dhis 2.21
Please help = EKANI Guy 


___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Problem generating resource tables

2016-08-23 Thread Wilfred Senyoni
Hi developers
I have experienced the same issue while creating a fresh database with
version 2.24 build revision: 23511.
Just to add on the new dataset interface you can create a new dataset
without a assigning a datasaet category combination while using the old
interface you are forced to choose one.

Cheers

Wilfred Senyoni
Information Systems Researcher
Skype: senyoni
Mob: (+255) 0713595231/(+47) 46573133

On Thu, Jul 14, 2016 at 9:25 PM, Knut Staring  wrote:

> https://bugs.launchpad.net/dhis2/+bug/1603179
>
> On Thu, Jul 14, 2016 at 8:08 PM, Knut Staring  wrote:
>
>> Ok, so I have tracked this down to a missing (NULL) value for
>> categorycomboid in the dataset table. It should have been filled with the
>> default value (15). I will file a bug report.
>>
>>
>>
>> On Thu, Jul 14, 2016 at 2:12 PM, Knut Staring  wrote:
>>
>>> So I started again with a blank db, first just adding a few orgunits and
>>> levels, and a couple of data elements. Generating resources tables then is
>>> fine.
>>>
>>> The error below happens as soon as I create a dataset. Any clues as to
>>> why?
>>>
>>> Knut
>>>
>>> On Thu, Jul 14, 2016 at 11:16 AM, Knut Staring  wrote:
>>>
 Hi there,

 I am building a 2.24 database from scratch/empty, and have so far just
 added a couple of OU and DE into a DataSet and entered a few values.

 Now when I try to generate the resource tables, I get the following.
 Any clues?

 * INFO  2016-07-14 11:13:38,901 [Level: INFO, category:
 RESOURCETABLE_UPDATE, time: Thu Jul 14 11:13:38 CEST 2016, message:
 Generating resource tables] (InMemoryNotifier.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,912 Create table SQL: create table
 _orgunitstructure_temp (organisationunitid integer not null primary key,
 organisationunituid character(11), level integer, "idlevel1" integer,
 "uidlevel1" character(11), "idlevel2" integer, "uidlevel2" character(11));
 (JdbcResourceTableStore.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,920 Populate table content rows: 3
 (JdbcResourceTableStore.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,923 Create index SQL: create unique index
 in_orgunitstructure_organisationunituid_k8awu on
 _orgunitstructure_temp(organisationunituid)
 (JdbcResourceTableStore.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,929 Swapped resource table, done:
 _orgunitstructure in: 00:00:00.025 (JdbcResourceTableStore.java
 [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,932 [Level: ERROR, category:
 RESOURCETABLE_UPDATE, time: Thu Jul 14 11:13:38 CEST 2016, message: Process
 failed: null] (InMemoryNotifier.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,932 'system-process' create
 org.hisp.dhis.message.MessageConversation, name: Resource table
 process failed, uid: BvFty94jh6y (AuditLogUtil.java [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,933 Message failed:  (SmsMessageSender.java
 [taskScheduler-3])

 * INFO  2016-07-14 11:13:38,933 Failure cause: no gateway is set to
 default (SmsMessageSender.java [taskScheduler-3])

 * ERROR 2016-07-14 11:13:38,941 Unexpected error occurred in scheduled
 task. (TaskUtils.java [taskScheduler-3])

 java.lang.NullPointerException

 at org.hisp.dhis.resourcetable.table.DataSetOrganisationUnitCategor
 yResourceTable.getPopulateTempTableContent(
 DataSetOrganisationUnitCategoryResourceTable.java:96)

 at org.hisp.dhis.resourcetable.jdbc.JdbcResourceTableStore.
 generateResourceTable(JdbcResourceTableStore.java:77)

 at org.hisp.dhis.resourcetable.DefaultResourceTableService.
 generateDataSetOrganisationUnitCategoryTable(
 DefaultResourceTableService.java:145)

 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

 at sun.reflect.NativeMethodAccessorImpl.invoke(
 NativeMethodAccessorImpl.java:62)

 at sun.reflect.DelegatingMethodAccessorImpl.invoke(
 DelegatingMethodAccessorImpl.java:43)

 at java.lang.reflect.Method.invoke(Method.java:498)

 at org.springframework.aop.support.AopUtils.
 invokeJoinpointUsingReflection(AopUtils.java:302)

 at org.springframework.aop.framework.ReflectiveMethodInvocation.
 invokeJoinpoint(ReflectiveMethodInvocation.java:190)

 at org.springframework.aop.framework.ReflectiveMethodInvocation.
 proceed(ReflectiveMethodInvocation.java:157)

 at org.springframework.transaction.interceptor.
 TransactionInterceptor$1.proceedWithInvocation(
 TransactionInterceptor.java:99)

 at org.springframework.transaction.interceptor.
 TransactionAspectSupport.invokeWithinTransaction(
 TransactionAspectSupport.java:281)

 at org.springframework.transaction.interceptor.
 

Re: [Dhis2-devs] GIS App Does Not Load and Just Hangs

2016-08-23 Thread Lorill Crees
Hi Jan,

I am just following up on the developer list thread with our offline
discussions for everyone's benefit. I've pasted your response below. We
will upgrade to 2.24 to fix this issue.

Cheers,

Lorill

On Tue, Aug 23, 2016 at 1:00 AM, Jan Henrik Øverland  wrote:

> Hi Lorill,
>
> Yes, we have done some testing and it seems nothing is wrong with your
> data or the GIS app.
>
> Turns out the way optionsets are handled on the server is not at all
> optimised in 2.22, but this has been taken care of in 2.24. The initial
> optionsets request that the GIS app does (which times out for you in 2.22)
> should load in less than a second in 2.24..
>
> I have talked to the backend guys and they say that this is unfortunately
> not a simple backport to 2.22. Any chance you could upgrade to 2.24? That
> will also provide you with a lot of nice new GIS functionality, like
> clustering of (millions of) events, access to Google Earth Engine layers
> etc.
>
> Jan
>

On Tue, Aug 16, 2016 at 10:20 AM, Lorill Crees  wrote:

> Hi Jan,
>
> I am checking with the team that owns this instance for permission to
> share the database with you and will get back to you.
>
> Thanks,
>
> Lorill
>
> On Tue, Aug 16, 2016 at 12:45 AM, Jan Henrik Øverland 
> wrote:
>
>> Hi Lorill,
>>
>> We are looking into ways to speed up the loading of option sets. Any
>> chance you could share a sample database privately so we can test it
>> properly?
>>
>> Jan
>>
>> On 16 August 2016 at 00:42, Lorill Crees  wrote:
>>
>>> Hi,
>>>
>>> Do you have any suggestions for this issue? We're currently blocked and
>>> not able to use the GIS app on this instance.
>>>
>>> Thanks,
>>>
>>> Lorill
>>>
>>> On Thu, Aug 11, 2016 at 12:00 PM, Lorill Crees 
>>> wrote:
>>>
 Hi,

 In a separate thread "GIS Google Maps Error" I had mentioned we are
 having an issue with one of our instances where the GIS app will not load
 and just hangs.

 After much investigation, we have tracked this down to one of the api
 calls that DHIS 2 is doing when loading the app to retrieve option sets.

 When viewing the browser network JS console, there is a call to
 /optionSets. It takes too long and times out (it gets cancelled). I've
 pasted the api call below. The result is that the GIS app just hangs and
 never loads.

 Further investigating, it looks like EXTJS has a default timeout of 30s
 which explains the timeout from within the DHIS 2 code. Performing the
 request outside of the DHIS 2 app returns OK, although the call takes
 almost 80 seconds to return.

 By the way, the instance has the DHIS 2 server setting of "no cache", I
 have used the Browser Cache Cleaner within DHIS 2, and also manually
 cleared the cache in my browser.

 I have also made a copy of the database locally, and am running the
 instance directly via Tomcat (no NGINX). I can sporadically recreate this
 as the return time for the call to optionSets is close to 30 seconds.
 Please see my two screenshots with the same url locally:

- when /optionSets returns under 30 seconds, the GIS app loads
properly
- when /optionSets returns over 30 seconds, the GIS app hangs

 One odd thing is that the api call being used locally for optionSets is
 slightly different than the one on the server, although they are both
 running the exact version / revision of DHIS 2 and I am calling the same
 url.

 We are using 2.22 R 22089.

 Any help would be appreciated!

 Thanks,

 Lorill

 

 *On Server:*

 url: https://[server]/dhis-web-mapping/index.html

 /api/optionSets.json?fields=id,displayName|rename(name),vers
 ion,options[code,displayName|rename(name)]=false&_dc=
 1470939760248

 *(*Cancelled at 30.00s) See screenshot

 When loading this url directly, it takes 79 seconds to return and the
 response is very large

 *On Localhost:*

 url: http://localhost:8090/dhis/dhis-web-mapping/index.html

 /api/optionSets.json?fields=id,version=false&_dc=1470934124633

- app loads when api call returns in 22.25 seconds
- app hang when api call cancelled at 30 seconds


>>>
>>> ___
>>> Mailing list: https://launchpad.net/~dhis2-devs
>>> Post to : dhis2-devs@lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>>
>> --
>> Jan Henrik Øverland
>> Software developer, DHIS 2
>> University of Oslo
>> http://www.dhis2.org 
>>
>
>
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : 

Re: [Dhis2-devs] [Bug 1612375] [NEW] Program indicators: error in percentage calculations when using d2:condition (inconsistent results at different levels of aggregation)

2016-08-23 Thread Sam Johnson
Hi all,

I reported a bug in the web program indicator calculations a couple of weeks 
ago, and included in the report everything that’s needed to quickly replicate 
the bug, but I don’t think anyone has had a chance to look at this report yet.

Have I followed the correct process for reporting this?  Is it at all possible 
to get an idea of when a fix for this might be available?  (It’s quite a 
serious bug, as ‘valid’ expressions are returning incorrect/inconsistent 
results at different levels of aggregation.)

Many thanks,

Sam.


From: Dhis2-devs 
 on behalf of 
Samuel Scott 
Reply-To: Bug 1612375 <1612...@bugs.launchpad.net>
Date: Thursday, 11 August 2016 at 19:21
To: DHIS2 Developers 
Subject: [Dhis2-devs] [Bug 1612375] [NEW] Program indicators: error in 
percentage calculations when using d2:condition (inconsistent results at 
different levels of aggregation)

Public bug reported:

Bug found in 2.22, still present in 2.24 online demo (2.24 rev.23557)
Online demo accessed using Chrome 52.0.2743.116.

There appears to be a bug in the program indicator calculations when:
a sum() custom aggregation is used twice, to enable the calculation of a 
percentage AND
an element of the percentage calculation includes d2:condition.

Note that either of these situations works properly on its own - ie the
numerator and denominator work perfectly when separated into two
different indicators - it is only when combined that the bug occurs.

TO REPRODUCE THIS BUG

In the online demo instance, using the Antenatal Care Visit program:

1. Create a program indicator called TestNumerator, with aggregation type 
'custom' and expression:
sum(d2:condition('#{dBwrot7S420.vANAXwtLwcT}>=10',1,0))

2. Create a program indicator called TestDenominator, with aggregation type 
'custom' and expression:
V{event_count}

3. Create a program indicator called TestPercentage, with aggregation type 
'custom' and expression, which combines these two expressions as a percentage:
sum(d2:condition('#{dBwrot7S420.vANAXwtLwcT}>=10',1,0)) / V{event_count} * 100

4. Create a pivot table based on the Antenatal program, add all three 
indicators to the pivot, and run it:
Numerator and denominator calculate correctly, but percentage returns 2/3 = 0 
(instead of 66.7)

5. Now change the Period from Last 12 months to Last 52 weeks, and re-run:
All indicators now calculate correctly, with percentage correctly showing 0/1 = 
0 and 2/2 = 100.


Note that this is not a bug in the event_count variable, as the same bug 
consistently appears even when V{event_count} is replaced by sum(1) in the 
indicator expressions.

I have a project whose viability depends on being able to correctly
calculate these percentages at higher levels of aggregation (regions
etc), so if confirmed as a bug, I would be hugely grateful if it were
possible to fix this in the current release, rather than in 2.25.

Many thanks, Sam.

** Affects: dhis2
 Importance: Undecided
 Status: New

--
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1612375

Title:
  Program indicators: error in percentage calculations when using
  d2:condition (inconsistent results at different levels of aggregation)

Status in DHIS:
  New

Bug description:
  Bug found in 2.22, still present in 2.24 online demo (2.24 rev.23557)
  Online demo accessed using Chrome 52.0.2743.116.

  There appears to be a bug in the program indicator calculations when:
  a sum() custom aggregation is used twice, to enable the calculation of a 
percentage AND
  an element of the percentage calculation includes d2:condition.

  Note that either of these situations works properly on its own - ie
  the numerator and denominator work perfectly when separated into two
  different indicators - it is only when combined that the bug occurs.

  TO REPRODUCE THIS BUG

  In the online demo instance, using the Antenatal Care Visit program:

  1. Create a program indicator called TestNumerator, with aggregation type 
'custom' and expression:
  sum(d2:condition('#{dBwrot7S420.vANAXwtLwcT}>=10',1,0))

  2. Create a program indicator called TestDenominator, with aggregation type 
'custom' and expression:
  V{event_count}

  3. Create a program indicator called TestPercentage, with aggregation type 
'custom' and expression, which combines these two expressions as a percentage:
  sum(d2:condition('#{dBwrot7S420.vANAXwtLwcT}>=10',1,0)) / V{event_count} * 100

  4. Create a pivot table based on the Antenatal program, add all three 
indicators to the pivot, and run it:
  Numerator and denominator calculate correctly, but percentage returns 2/3 = 0 
(instead of 66.7)

  5. Now change the Period from Last 12 months to Last 52 weeks, and re-run:
  All indicators now calculate correctly, with percentage correctly showing 0/1 
= 0 

Re: [Dhis2-devs] Application Security testing for DHIS 2

2016-08-23 Thread Greg Wilson
Aamer:

As part of the DATIM work, BAO is performing IBM AppScan vulnerability
assessment and confirmation. The results of these assessments will be
passed onto the development team for remediation. Due to the sensitive
nature of security vulnerabilities, we will follow standard, responsible
best practices regarding public disclosure. If critical, non-credentialed,
remote vulnerabilities are discovered we will attempt to provide
work-a-rounds until the devs can publish a remediated DHIS2 version.

This scanning will only involve DHIS2 core and apps that DATIM uses. We are
currently scanning v2.21 but will be jumping to 2.23 very soon. This will
be an ongoing, regular process. If you have any questions feel free to
contact me any time.

Gregory Wilson, CSSLP
BAO Systems, Inc.
gwil...@baosystems.com


On Tue, Aug 23, 2016 at 5:31 AM, Aamer Mohammed 
wrote:

> Hi dhis devs,
>
> We are looking for testing the application in areas which focus on "CIA
> triad" (Confidentiality, Integrity, Availability) of DHIS users and
> resources. Just wanted to check from DHIS devs if any kind of methodologies
> are already inplace for testing the code for below vulnerabilities.
> 1) Cross-site scripting attacks
> 2) Broken authentication attacks
> 3) Injection flaws
> 4) malicious code
>
> Thanks
> Aamer.
>
>
> On Fri, Jul 29, 2016 at 5:37 PM, Aamer Mohammed 
> wrote:
>
>> Hi Team,
>>
>> We are now beginning to look at application security of DHIS 2. We want
>> to understand if there is already any security testing in place for DHIS
>> and any guidelines around it. This will be helpful in security testing the
>> features which we have already contributed and the ones which we are
>> planning to.
>> It would be helpful if you get us started around this.
>>
>> Thanks
>> Aamer.
>>
>>
>
> ___
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to : dhis2-devs@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Greg Wilson
BAO Systems
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] [Bug 1614956] Re: Dataset Import/Export does not affect custom entry form

2016-08-23 Thread Timothy Harding
Thanks Morten!

The new build works as expected now :D tyvm

Quick question, Because there is no Data Entry Form in the "Meta Data
Detailed Exporter" might it be good to have the corresponding dataEntryForm
export by default when exporting a dataset?

This is the default export from that interface for a dataset:
[image: Inline image 1]

If you notice above  is a child  by *default*, *and*
there is no  tag. So you are unable to then take this xml
file and import it elsewhere without editing it first.




*Timothy Harding*
Sr. Systems Analyst, BAO Systems
+1 202-536-1541 | thard...@baosystems.com | http://www.baosystems.com | Skype:
hardi...@gmail.com | 2900 K Street, Suite 404, Washington D.C. 20007

On Mon, Aug 22, 2016 at 3:05 PM, Morten Olav Hansen <
1614...@bugs.launchpad.net> wrote:

> You need this
>
> 1) in data set, refer to the uid only, dataEntryForm: { id: "id123" }
>
> Thats it.. there was an issue with what we call the "internal merge
> strategy", basically we missed something when we converted dataEntryForm
> from an "normal" object to be an id object
>
> @Abyot
>
> --
> Morten Olav Hansen
> Senior Engineer, DHIS 2
> University of Oslo
> http://www.dhis2.org
>
> On Mon, Aug 22, 2016 at 9:04 PM, Timothy Harding 
> wrote:
>
> > Thanks Morten, testing now,
> >
> > Can you let me know where the  should live? Does it need to be
> in
> > there twice, or just the once underneath the  tag?
> >
> > like this:
> >
> > [image: Inline image 1]
> > and
> > [image: Inline image 2]
> >
> >
> > *Timothy Harding*
> > Sr. Systems Analyst, BAO Systems
> > +1 202-536-1541 | thard...@baosystems.com | http://www.baosystems.com |
> > Skype:
> > hardi...@gmail.com | 2900 K Street, Suite 404, Washington D.C. 20007
> >
> > On Mon, Aug 22, 2016 at 5:40 AM, Morten Olav Hansen <
> > 1614...@bugs.launchpad.net> wrote:
> >
> > > This should now be fixed in latest 2.23 and up
> > >
> > > ** Changed in: dhis2
> > >Status: Confirmed => Fix Committed
> > >
> > > ** Changed in: dhis2
> > >Status: Fix Committed => Fix Released
> > >
> > > --
> > > You received this bug notification because you are subscribed to the
> bug
> > > report.
> > > https://bugs.launchpad.net/bugs/1614956
> > >
> > > Title:
> > >   Dataset Import/Export does not affect custom entry form
> > >
> > > Status in DHIS:
> > >   Fix Released
> > >
> > > Bug description:
> > >   A few things going on here:
> > >
> > >   TL:DR
> > >   1. Dataset export does not contain the  tag as a
> child
> > > .
> > >   2. Dataset uploads with  as a child of  has
> no
> > > effect on the custom form
> > >   3. Dataset uploads with  as a child of 
> with
> > > matching entry under  still has no effect on custom form
> > >
> > >   Long Form:
> > >   1. I'm not sure where the intended location of the dataEntryForm
> custom
> > > HTML. If it is supposed to live as a child of , then all is
> > fine.
> > > If it is supposed to live in  with a link to it in
> > >  as I suspect, then exporting the dataSet should probably come
> > > with the  even if "Export With Dependencies" is _not_
> > > checked. It is also strange to see the custom HTML twice when you do
> > export
> > > with Dependencies. Which one is correct? It can also constrain a
> > > questionable connection if the custom form is very large, as the xml
> file
> > > is now doubled in size.
> > >
> > >   2. If I alter an exiting custom form in the  section and try
> > >   to upload the xml for it, it will not have any affect. See the video
> > >   of this in action and the link to the xml file I'm using to do this
> on
> > >   the play demo site. This behavior is the exact same for 2.23, where I
> > >   first encountered it.
> > >
> > >   3. As above, if I alter an exiting custom form in the
> 
> > >   section of the xml file, and try to upload the xml for it, it will
> not
> > >   have any affect. See the video of this in action and the link to the
> > >   xml file I'm using to do this on the play demo site. This behavior is
> > >   the exact same for 2.23, where I first encountered it.
> > >
> > >   Steps to Reproduce:
> > >   1. Log in as superuser
> > >   2. Download the following xml files, alter the
> name,shortname,code,uid
> > > and upload to playdemo
> > >   3. Make a an additional change to the custom form and upload to play
> > > demo, notice nothing actually changes.
> > >
> > >   Without the Entry Form
> > >   https://drive.google.com/open?id=0B9eJ8PZ_4csMcHlIalZTcUNGWkk
> > >
> > >   With the Entry Form
> > >   https://drive.google.com/open?id=0B9eJ8PZ_4csMRTNHanNYbmJGUFk
> > >
> > >   Video In Action:
> > >   https://drive.google.com/open?id=0B9eJ8PZ_4csMYmtYWnJJN1Rtc2M
> > >
> > > To manage notifications about this bug go to:
> > > https://bugs.launchpad.net/dhis2/+bug/1614956/+subscriptions
> > >
> >
> >
> > ** Attachment added: "image.png"
> >https://bugs.launchpad.net/bugs/1614956/+attachment/
> > 4725764/+files/image.png
> >
> > ** Attachment added: "image.png"
> 

Re: [Dhis2-devs] [Bug 1614543] Re: Dry run Alters Data 2.23

2016-08-23 Thread Timothy Harding
Thanks Morten. I will give the /23/ a shot for sure!

As far as the cache preheat, that is a stumper. I turn it off for most of
my imports because with DATIM it is the difference between a 300 second
import and an 800 second import. Thanks for looking into this.


*Timothy Harding*
Sr. Systems Analyst, BAO Systems
+1 202-536-1541 | thard...@baosystems.com | http://www.baosystems.com | Skype:
hardi...@gmail.com | 2900 K Street, Suite 404, Washington D.C. 20007

On Tue, Aug 23, 2016 at 2:28 AM, Morten Olav Hansen <
1614...@bugs.launchpad.net> wrote:

> This is strange.. but seems this is only true if preheatCache=false, if
> preheating is enabled.. it seems to work as intended.. I will try and
> fix it, but not sure what is causing this
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1614543
>
> Title:
>   Dry run Alters Data 2.23
>
> Status in DHIS:
>   Confirmed
>
> Bug description:
>   Hello devs!
>
>   Just found in 2.23 a bug that will alter metadata during a dry run.
>
>   Also, if someone come point me at the documentation for the logic for
>   updating existing objects? Right now if a name is the same, it will
>   alter the existing code and uid to the incoming code and uid rather
>   than erroring out, which to me seems like a bad idea to ever edit a
>   UID.
>
>   You can see an example of this here:
>
>   The video is in 4k, so if you have trouble seeing it at 1080p, go ahead
> and download it from this link.
>   https://drive.google.com/file/d/0B9eJ8PZ_4csMd1ZYQnBVb081X1k/view?usp=
> sharing
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/dhis2/+bug/1614543/+subscriptions
>


** Attachment added: "PastedGraphic-1.png"
   
https://bugs.launchpad.net/bugs/1614543/+attachment/4726328/+files/PastedGraphic-1.png

-- 
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1614543

Title:
  Dry run Alters Data 2.23

Status in DHIS:
  Confirmed

Bug description:
  Hello devs!

  Just found in 2.23 a bug that will alter metadata during a dry run.

  Also, if someone come point me at the documentation for the logic for
  updating existing objects? Right now if a name is the same, it will
  alter the existing code and uid to the incoming code and uid rather
  than erroring out, which to me seems like a bad idea to ever edit a
  UID.

  You can see an example of this here:

  The video is in 4k, so if you have trouble seeing it at 1080p, go ahead and 
download it from this link.
  https://drive.google.com/file/d/0B9eJ8PZ_4csMd1ZYQnBVb081X1k/view?usp=sharing

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1614543/+subscriptions

___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] [Dhis2-users] Error in DHIS2

2016-08-23 Thread Lars Helge Øverland
Hi Ravi,

most likely this is caused by wrong database credentials. Please double
check that your database name, username and password are correct. You can
try to log into your database using psql from the command line to verify.

psql -d dhis_db -U postgres


regards,

Lars


On Tue, Aug 23, 2016 at 11:57 AM, Chandrasekar Ravi 
wrote:

> Thanks for Reply.
>
> DHIS_HOME directory hibernate.properties file
>
> The following information in that file
>
> hibernate.dialect = org.hibernate.dialect.PostgreSQLDialect
> hibernate.connection.driver_class = org.postgresql.Driver
> hibernate.connection.url = jdbc:postgresql:dhis_db
> hibernate.connection.username = postgres
> hibernate.connection.password = 
> hibernate.hbm2ddl.auto = update
>
>
> Thanks & Regards
>
> *Chandrasekar Ravi*
> *Scientist - C, Data Manager*
>
> *GHSA MAHA CDC Project*
>
>
> *National Institute of Epidemiology, ICMR127, Second Main Road,
> TNHBAyapakkam, Ambattur, Chennai – 77*
> *aravindr...@gmail.com ,*
> *9787214185*
>
> On Tue, Aug 23, 2016 at 3:16 PM, Michael Mwebaze <
> michael.mweb...@gmail.com> wrote:
>
>> Hi Ravi,
>>
>> do you have the environment variable DHIS2_HOME pointing to the directory
>> containing either hibernate.properties or dhis.conf configuration files?
>> Below is a link to a sample configuration file and you can just limit to
>> the section 'Database connection for PostgreSQL'
>>
>> http://dhis2.github.io/dhis2-docs/2.22/en/implementer/html/ch08s07.html
>>
>> Regards,
>>
>> Michael
>>
>> On 23 August 2016 at 01:10, Chandrasekar Ravi 
>> wrote:
>>
>>> Dear Team,
>>>
>>> When i am trying to open the dhis2 software in web browser. It shows the
>>> following error. How to rectify it?
>>>
>>> : org.springframework.transaction.CannotCreateTransactionException:
>>> Could not open Hibernate Session for transaction; nested exception is
>>> org.hibernate.exception.GenericJDBCException: Unable to acquire JDBC
>>> Connection
>>>
>>> Thanks & Regards
>>>
>>> *Chandrasekar Ravi*
>>> *Scientist - C, Data Manager*
>>>
>>> *GHSA MAHA CDC Project*
>>>
>>>
>>> *National Institute of Epidemiology, ICMR127, Second Main Road,
>>> TNHBAyapakkam, Ambattur, Chennai – 77*
>>> *aravindr...@gmail.com ,*
>>> *9787214185 <9787214185>*
>>>
>>> ___
>>> Mailing list: https://launchpad.net/~dhis2-users
>>> Post to : dhis2-us...@lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~dhis2-users
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>
> ___
> Mailing list: https://launchpad.net/~dhis2-users
> Post to : dhis2-us...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-users
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Lars Helge Øverland
Lead developer, DHIS 2
University of Oslo
Skype: larshelgeoverland
l...@dhis2.org
http://www.dhis2.org 
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] [Dhis2-users] ANALYTICS ENGINE IN MAINTENANCE MODE, TRY AGAIN

2016-08-23 Thread Stanley Kalyati
Thank you Lars it has worked.

Best

-Original Message-
From: "Lars Helge Øverland" 
Sent: ‎23/‎08/‎2016 12:54
To: "Stanley Kalyati" 
Cc: "DHIS Users" ; "DHIS 2 Developers list" 

Subject: Re: [Dhis2-users] ANALYTICS ENGINE IN MAINTENANCE MODE,TRY AGAIN

Hi Stanly,


you can go to Apps > Settings > General and uncheck "Put anaylytics in 
maintenance mode" to disable this.


regards,


Lars




On Tue, Aug 23, 2016 at 12:36 PM, Stanley Kalyati  wrote:

Dear Colleagues,


I am now confused please help.I run maintenance mode yesterday and then cleared 
cache for both DHIS2 and web browser.


Since then i cant see my pivot tables or graphs.


Whenever i run the Visualiser am getting this error: "Code 503 ,Status Service 
unavailable"


"Analytics engine is in maintenance mode,try again."


What does this mean and how can i correct this.


Thank you for your help.


Stanley

___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-us...@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp







-- 

Lars Helge Øverland

Lead developer, DHIS 2
University of Oslo
Skype: larshelgeoverland
l...@dhis2.org

http://www.dhis2.org___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] [Dhis2-users] ANALYTICS ENGINE IN MAINTENANCE MODE, TRY AGAIN

2016-08-23 Thread Lars Helge Øverland
Hi Stanly,

you can go to Apps > Settings > General and uncheck "Put anaylytics in
maintenance mode" to disable this.

regards,

Lars


On Tue, Aug 23, 2016 at 12:36 PM, Stanley Kalyati 
wrote:

> Dear Colleagues,
>
> I am now confused please help.I run maintenance mode yesterday and then
> cleared cache for both DHIS2 and web browser.
>
> Since then i cant see my pivot tables or graphs.
>
> Whenever i run the Visualiser am getting this error: "Code 503 ,Status
> Service unavailable"
>
> "Analytics engine is in maintenance mode,try again."
>
> What does this mean and how can i correct this.
>
> Thank you for your help.
>
> Stanley
>
> ___
> Mailing list: https://launchpad.net/~dhis2-users
> Post to : dhis2-us...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-users
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Lars Helge Øverland
Lead developer, DHIS 2
University of Oslo
Skype: larshelgeoverland
l...@dhis2.org
http://www.dhis2.org 
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] ANALYTICS ENGINE IN MAINTENANCE MODE,TRY AGAIN

2016-08-23 Thread Stanley Kalyati
Dear Colleagues,

I am now confused please help.I run maintenance mode yesterday and then
cleared cache for both DHIS2 and web browser.

Since then i cant see my pivot tables or graphs.

Whenever i run the Visualiser am getting this error: "Code 503 ,Status
Service unavailable"

"Analytics engine is in maintenance mode,try again."

What does this mean and how can i correct this.

Thank you for your help.

Stanley
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] [Dhis2-users] Error in DHIS2

2016-08-23 Thread Michael Mwebaze
Hi Ravi,

do you have the environment variable DHIS2_HOME pointing to the directory
containing either hibernate.properties or dhis.conf configuration files?
Below is a link to a sample configuration file and you can just limit to
the section 'Database connection for PostgreSQL'

http://dhis2.github.io/dhis2-docs/2.22/en/implementer/html/ch08s07.html

Regards,

Michael

On 23 August 2016 at 01:10, Chandrasekar Ravi  wrote:

> Dear Team,
>
> When i am trying to open the dhis2 software in web browser. It shows the
> following error. How to rectify it?
>
> : org.springframework.transaction.CannotCreateTransactionException: Could
> not open Hibernate Session for transaction; nested exception is
> org.hibernate.exception.GenericJDBCException: Unable to acquire JDBC
> Connection
>
> Thanks & Regards
>
> *Chandrasekar Ravi*
> *Scientist - C, Data Manager*
>
> *GHSA MAHA CDC Project*
>
>
> *National Institute of Epidemiology, ICMR127, Second Main Road,
> TNHBAyapakkam, Ambattur, Chennai – 77*
> *aravindr...@gmail.com ,*
> *9787214185 <9787214185>*
>
> ___
> Mailing list: https://launchpad.net/~dhis2-users
> Post to : dhis2-us...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-users
> More help   : https://help.launchpad.net/ListHelp
>
>
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Application Security testing for DHIS 2

2016-08-23 Thread Aamer Mohammed
Hi dhis devs,

We are looking for testing the application in areas which focus on "CIA
triad" (Confidentiality, Integrity, Availability) of DHIS users and
resources. Just wanted to check from DHIS devs if any kind of methodologies
are already inplace for testing the code for below vulnerabilities.
1) Cross-site scripting attacks
2) Broken authentication attacks
3) Injection flaws
4) malicious code

Thanks
Aamer.


On Fri, Jul 29, 2016 at 5:37 PM, Aamer Mohammed 
wrote:

> Hi Team,
>
> We are now beginning to look at application security of DHIS 2. We want to
> understand if there is already any security testing in place for DHIS and
> any guidelines around it. This will be helpful in security testing the
> features which we have already contributed and the ones which we are
> planning to.
> It would be helpful if you get us started around this.
>
> Thanks
> Aamer.
>
>
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Upgrading to 2.24 and /api/24/metadata issue

2016-08-23 Thread Morten Olav Hansen
Maybe you should turn of PG logging the DDL statements.. maybe there is
startdate failed because of xyz, could be useful in hunting down the issue..

-- 
Morten Olav Hansen
Senior Engineer, DHIS 2
University of Oslo
http://www.dhis2.org

On Tue, Aug 23, 2016 at 3:55 PM, Vanya Seth  wrote:

> Well its very strange as this works fine in our local machines.
>
> On the VM's even tried dropping the db, creating new and then deploying
> the war. Still to no avail.
>
> Mostly this manual creation of columns should work. But what if there are
> other such things that might have been missed and will only come up when we
> try to do some operations.
>
> Regards
> Vanya
>
> On Tue, Aug 23, 2016 at 1:06 PM, Morten Olav Hansen 
> wrote:
>
>> That sounds strange Vanya, looked at the HBM files and there was nothing
>> special about those fields.
>>
>> Could you try a manual add:
>> alter table mapview add column startdate timestamp without time zone
>> alter table mapview add column enddate timestamp without time zone
>>
>> and see if that fixes it (I haven't seen this issue anywhere else, so
>> could be something very local)
>>
>> --
>> Morten Olav Hansen
>> Senior Engineer, DHIS 2
>> University of Oslo
>> http://www.dhis2.org
>>
>> On Tue, Aug 23, 2016 at 1:59 PM, Vanya Seth 
>> wrote:
>>
>>>
>>> Hello devs
>>>
>>> We were updating our test VM's to 2.24 from 2.21. We did it in an
>>> incremental manner.
>>> Apparently on few of the VM's after upgrade the /api/24/metadata (GET)
>>> call is failing with the following error:
>>>
>>> WARN  2016-08-23 11:47:59,957 SQL Error: 0, SQLState: 42703
>>> (SqlExceptionHelper.java [http-bio-8080-exec-8])
>>> * ERROR 2016-08-23 11:47:59,957 ERROR: column this_.startdate does not
>>> exist
>>>   Position: 463 (SqlExceptionHelper.java [http-bio-8080-exec-8])
>>> org.hibernate.exception.SQLGrammarException: could not extract
>>> ResultSet
>>>
>>> We checked the startup logs and there was no specific error around table
>>> update errors. It seems the mapview relation now has two new columns
>>> 'startdate' and 'enddate'. These are not getting created during the
>>> deployment and hence the metadata export call is failing.
>>>
>>> Tried stopping the server and restarting it multiple times but to no
>>> avail.
>>>
>>> Can you please look into this and let know what could be causing this
>>> strange issue.
>>>
>>> --
>>> With Regards
>>> Vanya
>>>
>>> ThoughtWorks Technologies
>>> Hyderabad
>>>
>>> --Stay Hungry Stay Foolish!!
>>>
>>> ___
>>> Mailing list: https://launchpad.net/~dhis2-devs
>>> Post to : dhis2-devs@lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>
>
> --
> With Regards
> ThoughtWorks Technologies
> Hyderabad
>
> --Stay Hungry Stay Foolish!!
>
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Upgrading to 2.24 and /api/24/metadata issue

2016-08-23 Thread Vanya Seth
We can try that.

Regards
Vanya

On Tue, Aug 23, 2016 at 2:34 PM, Morten Olav Hansen 
wrote:

> Maybe you should turn of PG logging the DDL statements.. maybe there is
> startdate failed because of xyz, could be useful in hunting down the issue..
>
> --
> Morten Olav Hansen
> Senior Engineer, DHIS 2
> University of Oslo
> http://www.dhis2.org
>
> On Tue, Aug 23, 2016 at 3:55 PM, Vanya Seth 
> wrote:
>
>> Well its very strange as this works fine in our local machines.
>>
>> On the VM's even tried dropping the db, creating new and then deploying
>> the war. Still to no avail.
>>
>> Mostly this manual creation of columns should work. But what if there are
>> other such things that might have been missed and will only come up when we
>> try to do some operations.
>>
>> Regards
>> Vanya
>>
>> On Tue, Aug 23, 2016 at 1:06 PM, Morten Olav Hansen 
>> wrote:
>>
>>> That sounds strange Vanya, looked at the HBM files and there was nothing
>>> special about those fields.
>>>
>>> Could you try a manual add:
>>> alter table mapview add column startdate timestamp without time zone
>>> alter table mapview add column enddate timestamp without time zone
>>>
>>> and see if that fixes it (I haven't seen this issue anywhere else, so
>>> could be something very local)
>>>
>>> --
>>> Morten Olav Hansen
>>> Senior Engineer, DHIS 2
>>> University of Oslo
>>> http://www.dhis2.org
>>>
>>> On Tue, Aug 23, 2016 at 1:59 PM, Vanya Seth 
>>> wrote:
>>>

 Hello devs

 We were updating our test VM's to 2.24 from 2.21. We did it in an
 incremental manner.
 Apparently on few of the VM's after upgrade the /api/24/metadata (GET)
 call is failing with the following error:

 WARN  2016-08-23 11:47:59,957 SQL Error: 0, SQLState: 42703
 (SqlExceptionHelper.java [http-bio-8080-exec-8])
 * ERROR 2016-08-23 11:47:59,957 ERROR: column this_.startdate does not
 exist
   Position: 463 (SqlExceptionHelper.java [http-bio-8080-exec-8])
 org.hibernate.exception.SQLGrammarException: could not extract
 ResultSet

 We checked the startup logs and there was no specific error around
 table update errors. It seems the mapview relation now has two new columns
 'startdate' and 'enddate'. These are not getting created during the
 deployment and hence the metadata export call is failing.

 Tried stopping the server and restarting it multiple times but to no
 avail.

 Can you please look into this and let know what could be causing this
 strange issue.

 --
 With Regards
 Vanya

 ThoughtWorks Technologies
 Hyderabad

 --Stay Hungry Stay Foolish!!

 ___
 Mailing list: https://launchpad.net/~dhis2-devs
 Post to : dhis2-devs@lists.launchpad.net
 Unsubscribe : https://launchpad.net/~dhis2-devs
 More help   : https://help.launchpad.net/ListHelp


>>>
>>
>>
>> --
>> With Regards
>> ThoughtWorks Technologies
>> Hyderabad
>>
>> --Stay Hungry Stay Foolish!!
>>
>
>


-- 
With Regards
ThoughtWorks Technologies
Hyderabad

--Stay Hungry Stay Foolish!!
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Upgrading to 2.24 and /api/24/metadata issue

2016-08-23 Thread Vanya Seth
Well its very strange as this works fine in our local machines.

On the VM's even tried dropping the db, creating new and then deploying the
war. Still to no avail.

Mostly this manual creation of columns should work. But what if there are
other such things that might have been missed and will only come up when we
try to do some operations.

Regards
Vanya

On Tue, Aug 23, 2016 at 1:06 PM, Morten Olav Hansen 
wrote:

> That sounds strange Vanya, looked at the HBM files and there was nothing
> special about those fields.
>
> Could you try a manual add:
> alter table mapview add column startdate timestamp without time zone
> alter table mapview add column enddate timestamp without time zone
>
> and see if that fixes it (I haven't seen this issue anywhere else, so
> could be something very local)
>
> --
> Morten Olav Hansen
> Senior Engineer, DHIS 2
> University of Oslo
> http://www.dhis2.org
>
> On Tue, Aug 23, 2016 at 1:59 PM, Vanya Seth 
> wrote:
>
>>
>> Hello devs
>>
>> We were updating our test VM's to 2.24 from 2.21. We did it in an
>> incremental manner.
>> Apparently on few of the VM's after upgrade the /api/24/metadata (GET)
>> call is failing with the following error:
>>
>> WARN  2016-08-23 11:47:59,957 SQL Error: 0, SQLState: 42703
>> (SqlExceptionHelper.java [http-bio-8080-exec-8])
>> * ERROR 2016-08-23 11:47:59,957 ERROR: column this_.startdate does not
>> exist
>>   Position: 463 (SqlExceptionHelper.java [http-bio-8080-exec-8])
>> org.hibernate.exception.SQLGrammarException: could not extract ResultSet
>>
>> We checked the startup logs and there was no specific error around table
>> update errors. It seems the mapview relation now has two new columns
>> 'startdate' and 'enddate'. These are not getting created during the
>> deployment and hence the metadata export call is failing.
>>
>> Tried stopping the server and restarting it multiple times but to no
>> avail.
>>
>> Can you please look into this and let know what could be causing this
>> strange issue.
>>
>> --
>> With Regards
>> Vanya
>>
>> ThoughtWorks Technologies
>> Hyderabad
>>
>> --Stay Hungry Stay Foolish!!
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-devs@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>


-- 
With Regards
ThoughtWorks Technologies
Hyderabad

--Stay Hungry Stay Foolish!!
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] Reporting rates in analytics - 0 vs not expected

2016-08-23 Thread Olav Poppe
Hi devs,
I’m a bit confused about the way the completeness analytics API works - I 
suspect there might be a bug when looking at the facility level (i.e. the level 
where data is entered):
- there is no difference between "not expected to report" and "not reported" - 
I would expect not reported to be 0 (%) and not expected to report to be 
blank/null
- facilities with no reports in a particular period is not showing with 
"expected reports" = 1. This might explain the above point, since they would 
not have a denominator.

At higher levels, everything works fine - expected is counted correctly. In my 
case, I’ve tested with a district with 30 facilities, 26 of which is expected 
to report. Doing a district level request gives actual reports 24, expected 26 
for a particular month. However, looking at the individual facilities in that 
district, the sum of "expected" is 24 and "actual" is 24, thus it is not 
possible to actually identify which facilities have not reported…

And a related issue: would it make sense to have actual reports be 0 instead of 
null for facilities that are expected to report, but have not yet reported? 
Then the completeness is 0/1 = 0% rather than null/1 which is (I guess) null - 
I would argue that is more "correct".

This is BTW with 2.24.

Regards
Olav
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] Upgrading to 2.24 and /api/24/metadata issue

2016-08-23 Thread Morten Olav Hansen
That sounds strange Vanya, looked at the HBM files and there was nothing
special about those fields.

Could you try a manual add:
alter table mapview add column startdate timestamp without time zone
alter table mapview add column enddate timestamp without time zone

and see if that fixes it (I haven't seen this issue anywhere else, so could
be something very local)

-- 
Morten Olav Hansen
Senior Engineer, DHIS 2
University of Oslo
http://www.dhis2.org

On Tue, Aug 23, 2016 at 1:59 PM, Vanya Seth  wrote:

>
> Hello devs
>
> We were updating our test VM's to 2.24 from 2.21. We did it in an
> incremental manner.
> Apparently on few of the VM's after upgrade the /api/24/metadata (GET)
> call is failing with the following error:
>
> WARN  2016-08-23 11:47:59,957 SQL Error: 0, SQLState: 42703
> (SqlExceptionHelper.java [http-bio-8080-exec-8])
> * ERROR 2016-08-23 11:47:59,957 ERROR: column this_.startdate does not
> exist
>   Position: 463 (SqlExceptionHelper.java [http-bio-8080-exec-8])
> org.hibernate.exception.SQLGrammarException: could not extract ResultSet
>
> We checked the startup logs and there was no specific error around table
> update errors. It seems the mapview relation now has two new columns
> 'startdate' and 'enddate'. These are not getting created during the
> deployment and hence the metadata export call is failing.
>
> Tried stopping the server and restarting it multiple times but to no
> avail.
>
> Can you please look into this and let know what could be causing this
> strange issue.
>
> --
> With Regards
> Vanya
>
> ThoughtWorks Technologies
> Hyderabad
>
> --Stay Hungry Stay Foolish!!
>
> ___
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to : dhis2-devs@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] DHIS2 Live Database file - reg

2016-08-23 Thread Chandrasekar Ravi
Dear All,

We are implemented DHIS2 tracker capture and data capture with DHIS2 Live.
I need to open the database file (Dhis2 Live -> database -> dhis2.trace.db)
. If i am using SQL lite to retrieve data it ask password to open. What
password I need to give?


Thanks & Regards

*Chandrasekar Ravi*
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-devs] scheduling in DHIS

2016-08-23 Thread Vanya Seth
Hi Halvdan

We will extend the functionality and send a patch.

Regards
Vanya

On Mon, Aug 22, 2016 at 5:57 PM, Halvdan Hoem Grelland 
wrote:

> Vanya,
>
> If you're talking about simply exposing 
> TaskExecutor.submitListenable(Runnable)
> in the Scheduler interface, it's not a big deal. I'd think you could just
> go ahead. Alternately you could wire the AsyncListenableTaskExecutor bean
> directly into the service, I suppose.
>
> On Mon, Aug 22, 2016 at 12:55 PM, Vanya Seth 
> wrote:
>
>> Hi Lars
>>
>> Any comments on this one?
>>
>> Regards
>> Vanya
>>
>> On Wed, Aug 17, 2016 at 12:44 PM, Vanya Seth 
>> wrote:
>>
>>> Hi Lars
>>>
>>> We are looking at extending org.hisp.dhis.system.scheduling.Scheduler to
>>> also have the ability to return the ListenableFuture for a Runnable as
>>> well. This will help us or any dev in the future to check the status of the
>>> ongoing Runnables in the system and provide some user experience around it.
>>>
>>> Please let know if you are ok with us taking it up? As we want to fix a
>>> bug wherein the "sync now" button should not be clickable if the task is
>>> already running.
>>>
>>> Regards
>>> Vanya
>>>
>>>
>>> On Mon, Aug 8, 2016 at 9:26 AM, Aamer Mohammed 
>>> wrote:
>>>
 Hi Lars/Morten,

 The scheduling page in DHIS 2.24 has ability to run tasks immediately
 in below sections.

- Metadata Synchronization - Using 'Sync Now' button
- SMS Scheduler - Using 'Run Now' button

 When the user clicks 'Sync Now' button, an asynchronous task is
 triggered in the backend for metadata synchronization. The user can click
 the button again before the synchronization task is even complete. We want
 to prevent this as it can spawn multiple threads in the system all doing
 the same job leading to race conditions in system.

 We can do the changes in SchedulingManager.executeTask so that it will
 check the status of the previously submitted task. If it is not running
 then it will start new task or otherwise not. These changes should be
 applicable to any 'executeNow' type tasks in the system.

 Does DHIS2 already have such functionality available elsewhere in the
 system? Any thoughts on this approach.


 Thanks
 Aamer.

>>>
>>>
>>>
>>> --
>>> With Regards
>>> ThoughtWorks Technologies
>>> Hyderabad
>>>
>>> --Stay Hungry Stay Foolish!!
>>>
>>
>>
>>
>> --
>> With Regards
>> ThoughtWorks Technologies
>> Hyderabad
>>
>> --Stay Hungry Stay Foolish!!
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-devs@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Halvdan Hoem Grelland
> Software developer, DHIS 2
> University of Oslo
> http://www.dhis2.org 
>
>


-- 
With Regards
ThoughtWorks Technologies
Hyderabad

--Stay Hungry Stay Foolish!!
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] Upgrading to 2.24 and /api/24/metadata issue

2016-08-23 Thread Vanya Seth
Hello devs

We were updating our test VM's to 2.24 from 2.21. We did it in an
incremental manner.
Apparently on few of the VM's after upgrade the /api/24/metadata (GET) call
is failing with the following error:

WARN  2016-08-23 11:47:59,957 SQL Error: 0, SQLState: 42703
(SqlExceptionHelper.java [http-bio-8080-exec-8])
* ERROR 2016-08-23 11:47:59,957 ERROR: column this_.startdate does not
exist
  Position: 463 (SqlExceptionHelper.java [http-bio-8080-exec-8])
org.hibernate.exception.SQLGrammarException: could not extract ResultSet

We checked the startup logs and there was no specific error around table
update errors. It seems the mapview relation now has two new columns
'startdate' and 'enddate'. These are not getting created during the
deployment and hence the metadata export call is failing.

Tried stopping the server and restarting it multiple times but to no avail.

Can you please look into this and let know what could be causing this
strange issue.

-- 
With Regards
Vanya

ThoughtWorks Technologies
Hyderabad

--Stay Hungry Stay Foolish!!
___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp


[Dhis2-devs] [Bug 1614543] Re: Dry run Alters Data 2.23

2016-08-23 Thread Morten Olav Hansen
This is strange.. but seems this is only true if preheatCache=false, if
preheating is enabled.. it seems to work as intended.. I will try and
fix it, but not sure what is causing this

-- 
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1614543

Title:
  Dry run Alters Data 2.23

Status in DHIS:
  Confirmed

Bug description:
  Hello devs!

  Just found in 2.23 a bug that will alter metadata during a dry run.

  Also, if someone come point me at the documentation for the logic for
  updating existing objects? Right now if a name is the same, it will
  alter the existing code and uid to the incoming code and uid rather
  than erroring out, which to me seems like a bad idea to ever edit a
  UID.

  You can see an example of this here:

  The video is in 4k, so if you have trouble seeing it at 1080p, go ahead and 
download it from this link.
  https://drive.google.com/file/d/0B9eJ8PZ_4csMd1ZYQnBVb081X1k/view?usp=sharing

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1614543/+subscriptions

___
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp