cancel
Showing results for 
Search instead for 
Did you mean: 

how to MI Client initialize webapps

Former Member
0 Kudos

hello all,

i have tried the code for calling automatically webapps deployed locally:

<i> User currentUser = UserManager.getInstance().getCurrentUser() ;

MobileSolutionDescriptor[] msds =

ConversationIdHandler.getInstance().getAllMobileSolutionDescriptorsForUser(currentUser);

for (int idx=0; idx<msds.length; idx++) {

String appName = msds[idx].getName();

String appVer = msds[idx].getVersion();

String appDesc = msds[idx].getDescription();

String appNmSp = msds[idx].getNamespace();

boolean installed = msds[idx].isInstalled() ;

boolean incomplete = msds[idx].isIncomplete() ;

boolean failed = msds[idx].isFailed() ;</i>

but my problem is: if i have 2 webapps this code load only 1.

how my code can trace 2 webapp.

Accepted Solutions (1)

Accepted Solutions (1)

stefan_schwing
Active Participant
0 Kudos

Hi,

do you get the 404 error for the same application all the time ? Have you tried deploying only the 2 apps you get the error for on a device and see what happens ?

Answers (2)

Answers (2)

stefan_schwing
Active Participant
0 Kudos

Hi,

I am not quite sure what you mean by "if i have 2 webapps this code load only 1". I assume you are saying that the code you are using returns only one MSD while it should return two ? If so, maybe we need more details about your application and MI client.

Anyhow, the classes you are using here come from the package com.sap.ip.me.core . This is the actual implementation of the MI client which is subject to potential change. So if SAP decides in an upcoming SP to rename or remove the method getAllMobileSolutionDescriptorsForUser , your code will break. SAP will only guarantee that classes from com.sap.ip.me.api.* will not change , all others might change or disappear.

Cheers, Stefan

kishorg
Advisor
Advisor
0 Kudos

Hi Elina,

I think our present MI client cannot support two applications at a time. I dont know the exact reason.

Have u read the weblog "How to make an MI application name independent" posted by Jo.

/people/sap.user72/blog/2006/02/01/how-to-make-an-mi-application-name-independent

in this blog , Jo has specified a way to find out the installation path of the application. i think we can use this ... not sure

we are also in search of achieving this functionality.

if u r getting any solutions , then it is a great achievement.

Regards

Kishor Gopinathan

Former Member
0 Kudos

hello kishor,

in SP 13 Miclient support 1 or more webapp.

the only problem is that the metod SynchronizeWithBackend() syncronize all data in local repository.

kishorg
Advisor
Advisor
0 Kudos

Hi Elina,

could you work with that , without having any problem?.

i am asking this bcoz , i tried to install 3 applications at a time in the client..

successfully installed the application.

but only the first installed application is working properly. when i click on the 2nd and 3rd application link , i am getting the "page not found 404" error...

how could u resolve this problem...

according to SAP from sp13 itself , we can install multiple applications.. but its not working properly..

Regards

Kishor Gopinathan

Former Member
0 Kudos

hi kishor,

for this i have checked my 2 web.xml of these webapps.

check if the tags <servlet> are corrects.

i had the same problem and i have correct this editing this web.xml. i have redeployed my webapps and now the problem is solved.

Former Member
0 Kudos

hello kishor,

MI supports multiple applications; in fact you can install

the same application deployed in different MCD names.

if you are doing the latter scenario, you have to take note

of the applicationName string and the static variables in

your application. see also.

/people/sap.user72/blog/2006/02/01/how-to-make-an-mi-application-name-independent

regards

jo

kishorg
Advisor
Advisor
0 Kudos

Hi Jo ,

so i have to follow the entire steps u have given in the

weblog for achieving multiple applications to work in client?.

if i am normally creating 3 applications without any change in that Constants file(u have mentioned in the weblog), and assign these applications to the one client.will it work.. ?.

Regards

Kishor Gopinathan

Former Member
0 Kudos

hello kishor,

in the Constant class change the name of webapp as jo as writed & check your web.xml

Former Member
0 Kudos

hello kishor,

what i had described in the weblog is a workaround on how

to determine the deployment name assigned to your application

at runtime. when your application is returning the a hard

coded string in your getApplicationName method just like

the samples in the MDK, you must deploy or register it into

the WebConsole using the same string.

>if i am normally creating 3 applications without any change

> in that Constants file, and assign these applications to

> the one client.will it work.. ?.

as long as they are different applications and their

application names are unique (and with no space character),

they will be successfully deployed and can be executed in

the client...

regards

jo