LightCells.getInstance() throws java.io.IOException: You are using an evaluation copy and have opened files exceeding limitation

Hi,

We are using the Aspose.Cells version 2.4.0.1. We have a batch job which creates an Excel file that will be uploaded to repository.

In Production most of the batch jobs are getting failed due to the below given error.

]-[DiskLightCellEventGenerator-processWorkbook] - java.io.IOException: You are using an evaluation copy and have opened files exceeding limitation.
at com.aspose.cells.LightCells.a(Unknown Source)
at com.aspose.cells.LightCells.getInstance(Unknown Source)
at com.aspose.cells.LightCells.getInstance(Unknown Source)

After refering the log file which we have, the error is being thrown at LightCells.getInstance(diskWorkbookPath, FileFormatType.EXCEL2003);

We have the below piece of the code:

String diskWorkbookPath = workbookState.getDiskWorkbookFilePath();

try
{
lightCells = LightCells.getInstance(diskWorkbookPath, FileFormatType.EXCEL2003);
}
catch (IOException eIOException)
{
LOG.error(ExceptionUtils.getFullStackTrace(eIOException));

throw new ProgException(eIOException.getMessage() + " : Unable to locate the workbook at the location ["
+ diskWorkbookPath + "]");
}

Assert.notNull(lightCells, "Unable to locate the workbook at the location [" + diskWorkbookPath + "]");
..................
..................
..................

The above stated issue only started occuring recently, it was working fine before.

Please clarify at what situation we will get the error: java.io.IOException: You are using an evaluation copy and have opened files exceeding limitation,
and how to resolve this issue?

Regards

Karuppiah

Hi,

Please check whether you have set License fiile successfully for Aspose.Cells for Java and the licensing code is processed fine for your application life cycle. I think you are working in evaluation mode, In evaluation mode you can only open 150 files by LightCells APIs in the JVM environment.

Thank you.

Hi Amjad,

How do we confirm the license file which we are using is an Evaluation copy?

Regards

Karuppiah

Hi,

Please try some methods of the License class, e.g getSubscriptionExpireDate, isLicenseSet etc. see the API Reference:
http://www.aspose.com/documentation/java-components/aspose.cells-for-java/com/aspose/cells/license.html
We also recommend you to use latest version v2.5.0.

For your information, when you purchase the license, you are eligible to use versions / bug fixes of the product that are released in the next whole year. But if a version/fix is released after your subscription expiry date, you need to upgrade your subscription then.

It is quite possible that your licensing code might not be processed or your are using a version that is released your subscription expiry date.

Thank you.

Hi Amjad,

In Production environment we are not using evaluation copy. Since our license is valid till 07/19/2011. What do you think are the other reasons due to which this issue can come up?

Regards,

Karuppiah

Hi,

We think a possible reason for your issue. If you access the LightCells API before setting the license, you may get such kind of issue. We suggest you to set the license at first before accessing any other API including LightCells API.

Thank you.

Hi Amjad,

In our code we are setting the License in beginning of the batch process. After setting the License only we are using LightCells & other APIs. Any other reason might cause this issue?

Regards

Karuppiah

Hi Amjad,

Any updates on this issue?

Regards

Karuppiah

Hi,

Well, we only found one possibility that may cause the file’s count restriction with licensed usage of the product. In the next fix we will fix this bug and let you try it whether it can resolve your issue. We will try to give you this fix here within 3 days.

Thank you.

Hi Amjad,

Kindly provide the Lastest Aspose.cell jar with the fix you have mentioned and also please ensure that the current functionalities of version 2.4.0.1 (that we are using currently) are working fine.

Regards

Karuppiah M

Hi,

Yes sure, the new fix would include all the functionality of the previous versions / fixes.

Thank you.

Hi Amjad,

In the issue which was reported in Production environment, the file count has not even crossed 100 (meaning it did not cross the max limit). Is there any other specific reason that might cause this issue?

Regards

Karuppiah

Hi,

We have made some enhancement for checking license when using LightCells API. Please try the attached fix to check whether it can resolve your problem.

Kindly let us know if you still find any issue.

Thank you.

Amjad,

Thanks for the latest release of jar.

We wanted to know the answer for the below query.

In the issue which was reported in Production environment, the file count has not even crossed 100 (meaning it did not cross the max limit). Is there any other specific reason that might cause this issue?

Regards

Karuppiah

Hi,

Have you opened a file more than one time? We count the times you call LightCells.getInstance() in fact, so, if you process one file twice, we will take it as two files are processed. And the counter will be increased accordingly in the life-cycle of JVM. Anyways, if you are using a valid license, there should be no such kind of issue. Please try the new fix we provided to check whether it can solve your problem.

Thank you.

Hi Amjad,

We were trying out the latest version of Aspose 2.5.0.2 jar that you provided on 01-11-2011. When we start our application server (Tomcat) with this new version of Jar, we are encountering an exception java.lang.UnsupportedClassVersionError. Detailed stack tracker is given below.

Our application runs on JDK 1.4. Please confirm if Aspose 2.5.0.2 jar is compliant with JDK 1.4. We dint face this issue with the earlier version of Aspose jar 2.4.0.1.

Please let know about this at the earliest.

Detailed Stack Trace:

Caused by: java.lang.UnsupportedClassVersionError: com/aspose/cells/NamedRange (Unsupported major.minor version 49.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:539)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1649)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:931)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1373)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:1655)
at java.lang.Class.getDeclaredMethods(Class.java:1139)
at java.beans.Introspector$1.run(Introspector.java:1127)
at java.security.AccessController.doPrivileged(Native Method)
at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:1125)
at java.beans.Introspector.getTargetMethodInfo(Introspector.java:990)
at java.beans.Introspector.getBeanInfo(Introspector.java:371)
at java.beans.Introspector.getBeanInfo(Introspector.java:145)
at org.springframework.beans.CachedIntrospectionResults.(CachedIntrospectionResults.java:220)
at org.springframework.beans.CachedIntrospectionResults.forClass(CachedIntrospectionResults.java:144)
at org.springframework.beans.BeanWrapperImpl.getCachedIntrospectionResults(BeanWrapperImpl.java:252)
at org.springframework.beans.BeanWrapperImpl.getPropertyDescriptors(BeanWrapperImpl.java:259)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.filterPropertyDescriptorsForDependencyCheck(AbstractAutowireCapableBeanFactory.java:1131)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:990)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:470)
... 112 more

Thanks and Regards,

Karuppiah

Hi,

Well, I think we provided you the JDK1.5 compiled version of Aspose.Cells for Java. Please try our latest Aspose.Cells for Java v2.5.2.3 and use JDK1.4 version of the product from the archive.

Thank you.

Hi Amjad,

We have not yet promoted the jar you have provided to our Production environment.

Toyota (TMS) is our client. They are very concerned with this problem reccurring every now and then. It has been escalated to our Senior Management. TMS wants a proper explanation on this issue and an assurance that it will not reccur. Without this, they will not sign off on this new jar.

Can you let know what caused this issue and what is the fix that you have done in the latest version that would solve the problem?

Please treat this as high priority and provide an explanation at the earliest.

Thanks and Regards,

Karuppiah

Hi,

Well, the issue is just to use the improper component’s jar file with your JDK version. Commonly we give users the archive that contains only the jar for JDK1.5 because most of our users now have updated their JDK to v1.5 or later versions. Also, if you demand, we can give you the same version (2.5.0.2) for JDK1.4 for your need. For later fixes/versions, of course we have fixed some of other bugs and added some enhancements, you can check the release notes for versions v2.5.1 and v2.5.2 for more details. If you had told us you are using JDK1.4, then we would have provided you the JDK 1.4 version for your need.

Thank you.

Hi Amjad,

I was wanting to know the reason for the error and fix details for the issue in the current discussion chain "LightCells.getInstance() throws java.io.IOException: You are using an evaluation copy and have opened files exceeding limitation." and not for the JDK version difference.

Our application users have been getting this exception very frequetly in the past 2 months. So they want an assurance that the new jar you have provided will definitely resolve the cause for this exception.

They have demanded for the details on the root cause for this issue as well as the fix done.

Please provide the details.

Thanks and Regards,

Karuppiah.