Cordys: The value is not set for the parameter number

Today I ran into the following problem:

<log4j:event logger="com.cordys.xds.internal.transaction.query.XQYQuery" timestamp="1308643015133" level="ERROR" thread="Monitor Stream Reader Thread">
<log4j:message><![CDATA[Failed to execute query. Error: + '
<elem>Error :com.microsoft.sqlserver.jdbc.SQLServerException: The value is not set for the parameter number 1.</elem>
<log4j:MDC><![CDATA[host=cvzlaca004 processid=1314]]></log4j:MDC>
<log4j:throwable><![CDATA[com.cordys.xds.transaction.exception.DatabaseQueryException: Failed to execute query. Error: + '
<elem>Error :com.microsoft.sqlserver.jdbc.SQLServerException: The value is not set for the parameter number 1.</elem>
at com.cordys.xds.internal.transaction.query.XQYQuery.executeQuery(XQYQuery.java:221)
at com.cordys.xds.internal.branch.BranchDataCache.prepareParentBranchHierarchy(BranchDataCache.java:325)
at com.cordys.xds.internal.branch.BranchDataCache.loadCacheValueInternal(BranchDataCache.java:134)
at com.eibus.util.cache.Cache.loadCacheValue(Cache.java:375)
at com.eibus.util.cache.Cache.get(Cache.java:264)
at com.cordys.xds.internal.branch.BranchDataCache.get(BranchDataCache.java:217)
at com.cordys.xds.internal.branch.BranchManagerImpl.getBranchDataValue(BranchManagerImpl.java:443)
at com.cordys.xds.internal.branch.BranchManagerImpl.getBranch(BranchManagerImpl.java:421)
at com.cordys.xds.internal.branch.BranchManagerImpl.getBranch(BranchManagerImpl.java:411)
at com.cordys.xds.internal.service.XDSServiceImpl.isValidBranch(XDSServiceImpl.java:353)
at com.cordys.xds.internal.service.XDSServiceImpl.getServer(XDSServiceImpl.java:329)
at com.cordys.task.xds.TaskUtil.createTaskBranch(TaskUtil.java:168)
at com.cordys.applicationconnector.task.TaskConnector.open(TaskConnector.java:56)
at com.eibus.soap.Processor.open(Processor.java:752)
at com.eibus.soap.Processor.startProcessor(Processor.java:1036)
at com.eibus.soap.ProcessStreamsHandler.startProcessor(ProcessStreamsHandler.java:681)
at com.eibus.soap.ProcessStreamsHandler$StreamReader.run(ProcessStreamsHandler.java:353)
<log4j:locationInfo class="com.cordys.xds.util.XDSLogger" method="exception" file="XDSLogger.java" line="242"/>

The reason for this problem is that the user did not have enough privilage on the database to execute this query. So Cordys needs to have db_writer, db_reader AND db_owner rights on the database!

It took me half a day to figure this out, so hopefully this helps other Cordys developers !


Introduction to Cordys Cloud Provisioning


In my current Cordys project I am using the Cordys Cloud Provisioning (CCP) functionality of Cordys. I am very excited about this produkt and this blog item I will share my knowledge about it.
First I will explain something about provisioning.

What is Provisioning?
Provisioning is the process of managing Organizations (also called Tenants) and Users to let them use Applications. It manages the usage of applications that can be used as SaaS applications by tenants. It can be used to create new business models. Cordys has made a separate package for this, on top of BOP4 called CCP.

With CCP it is possible (among others):
  • Managing Cordys-Applications and non-Cordys applications
  • Managing of Tenants
  • Managing of Users and Roles
  • Keeping track of the usage of the Applications (Metering)

Some Terminology
The next picture shows the Cordys-ecosystem.

Tenant makes use of SaaS applications that are delivered by a PaaS. These applications are developed by Apps Provider (ISV).
Tenant Admin manages Users and Applications for a tenant. The End User is a user that uses the applications. A Sales Channel is a channel that sells applications for ISVs to other tenants.

Cordys is multi-tenant in the core

The nice part of Cordys is that the Cordys core is Tenant aware. This means that all usage of applications is done in the context of a tenant (in Cordys this is an Organization). Applications developed with Cordys must be made tenant aware. The result is that application data will have tenant info associated with it. In fact an Organization can be seen as a "container" with its own users, applications and security context.  This way tenants can not use data of other tenants. Users can only access an organization if it has a Role in that Organization. 

CCP Applications
Applications can be used by tenants and are defined in Cordys with CCP. Applications are defined with the use of ISV packages. For each Application the available Roles can be defined. You can define provisioning processes, properties and custom UIs that are being executed in case an organizations and/or users take a subscription.

Some example screens when defining a new Application through CCP.

Defining Roles.


Cordys is the only BPM produkt I know of, that has SaaS features within the core of the produkt. CCP is a fairly new addon to the Cordys BOP4 platform, but I expect a lot from it.


Address already in use error

During installation of Cordys BOP4 (CU17) we ran into the following problem.

I tried to change the client connection point address of the WebGateway, but still no success.

Eventually it appeared to be an Apache Config problem.

In <Apache_Install_Dir>/conf/extra/httpd-mpm.conf there is a setting.

# worker MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_worker_module>
    ServerLimit           1
    ThreadLimit         200
    StartServers          1
    MaxClients          200
    MinSpareThreads      25
    MaxSpareThreads     200 
    ThreadsPerChild     200
    MaxRequestsPerChild   0

The important setting here is StartServers. This value MUST be "1".