Swati Sisodia

Greenhorn
+ Follow
since Oct 28, 2007
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
1
Received in last 30 days
0
Total given
4
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Swati Sisodia

Hello fellow greenhorns,

This is Swati. Love this place, Javaranch!
I wanted some opinions on which certification to consider next in my career path. Here's my brief bio:
Software Engineer and Consultant for almost 10 years now - worked on Desktop, Mobile and Web applications, mostly in Java and other languages. I have earned 3 certifications in Java a few years ago:
> SCJP (for Java 5) (in 2008)
> Oracle Certified Professional, Java ME 1 Mobile Application Developer (in 2010)
> Oracle Certified Expert, Java EE 6 Web Component Developer (in 2013)

Currently, I am managing a small team and working on developing architecture of a few projects - in Java and else. I propose and develop solutions for client requirements. Sometimes I get my hands dirty with coding and other times I would develop the overall flow and architecture.
Now, I am considering going for next certification but not able to figure out which and also what would be prerequisite for that exam (I find the website for the exams a little confusing :P). I think Oracle Certified Master, Java EE 6 Enterprise Architect would be a good option. Is it true that I have to upgrade to Java 8 (1Z0-813 exam) before choosing any higher level certification? Would you rather recommend me taking another exam before taking Master level exam as part of preparation?

Any help on this would be highly appreciated.

- Swati
Hello all, I am fairly new to JSF and I am trying to implement a conditional flow of application when a user clicks a button / link on a dialog on my JSF page. I am able to show the dialog and a datagrid displaying all the options. On each panel of datagrid, there is an option for user to proceed a particular direction. There are three possible directions: 1. hide current dialog and show another dialog, 2. display a jsf page configured via pretty config, 3. redirect to url mapped to a controller in the same application. So far I got this:



Also, I am not sure of the component I should use (also not sure if that matters in my case) among h:commandLink h:commandButton, h:outputLink or equivalent p: components. Below is my bean method:



So far displaying another dialog in case of "facebook" is working. Redirecting to another jsf page (the default case) is also working but I see the second dialog for less than a second before it redirects to the desired page. And the third case of pinterest where I want to redirect to controller is not working at all.

Any help is much appreciated.
5 years ago
Hey, I just figured it out. Thanks so much Rob for pointing towards socket binding. After staring at my domain.xml for a few minutes, I noticed, the socket-binding for https under "standard-sockets" group was 8443. so I accessed https://localhost:8443/myApp Still "the site can't be reached" response. Then I realized I had set 500 as my port offset. So I tried https://localhost:8943/myApp and voila! I get the prompt to accept the certificate and after accepting, I see the home page.
Thanks again, Rob. You saved my day!

PS: I did not have to add connector to undertow subsystem. And socket-binding was already there, I got the correct https port from there.
5 years ago
Hi Rob, thanks for replying.
I used pure Java SSL-Setup to create the keystore.
You have pointed out a few (obvious :P) things I missed. :P
I have not setup the connector nor the port configuration (i.e., no socket binding). But I thought setting <ssl> under <server-identities> and setting <https-listener> in undertow subsystem was a replacement of that. [Not sure why I assumed that.]
In my undertow subsystem, I have an http-listener instead of a connector for http. Do you suggest I should add connector for only https or both https and http?
5 years ago
I have been struggling on this for 2 days now. I want to setup https listener on Wildfly 9.0.2.Final on my local Mac. I am new to wildfly. I have copied my wildfly settings (domain.xml and host.xml) from my production environment but on Prod we have load balancers to route to https traffic and I do not want to setup load balancers on my local. I have looked up on internet and got this far:
1. Generated a self-signed certificate following this link:
https://docs.jboss.org/author/pages/viewpage.action?pageId=66322705&_sscc=t
2. Added a security-realm in host.xml:


3. in domain.xml I have a couple of profiles setup, and each of them have a subsystem undertow. From my searches online, I understand that I need to add an https-listener in undertow subsystem. Now, its not very clear to me in which undertow subsystem, I add the https-listener. I still added it to the profile which my application is deployed under (because I want https listener for only one app on my local). Below is a section of my domain.xml:

   
The port for my application over http is 8580 (I have set port offset to be 500), i.e., I access my app on URL:
http://localhost:8580/myApp
When I go to any of :
https://localhost/ or https://localhost:8580 or https://localhost:443 or https://localhost/myApp
I just get "This site can't be reached. localhost refused to connect." response.
Being new to wildfly, I can not figure out where am I making a mistake, also what should be the port to access HTTPS URL.
Please let me know if I need to provide any more information.
Any help will be highly appreciated.
5 years ago
hmm.. what you said made perfect sense.. I did read up on security part of J2EE spec some time back and agree that is best way to handle authentication.. I guess I was too much into JSF and View Expiring mindset to skip that part.

But what you said made me think this..
I have noticed (in my debugging) that the UI view expires when session is expired and I have been testing this by changing my session timeouts in DD. So, that leaves me wondering.. what decides when a View is expired? Can it be configured in the application like session? Is it a true statement that when the value(s)/data (displayed on my view) changes on the server is when ViewExpiredException is thrown?
(I am fairly new at JSF so pardon me if my questions are too naive.. I have a feeling I need to read up on JSF spec for a better understanding but your explanations are helping Tim)
9 years ago
JSF
Thanks Tim,
That was a good explanation. After spending about 4 days on the problem, I have this feeling that displaying a dialog (and may be a count-down of session timing out) was not easily achievable without some script. I am not a big fan of JavaScript code lying in my JSPs/Facelets.
I found some utility library online built on top of JSF which redirects the user to the error page declared in my deployment descriptor even for ajax calls (not sure if I can name that library here), which solves my purpose for now... but I guess I will get back to this problem later.

Although, I have one thought to put on the table..
The redirection to timeout screen can be done either via handling ViewExpiredException or in plain old Filter class, so, wouldn't it be better to stop an unauthenticated user right at the filter.. before the request even makes it where ViewExpiredException is thrown. I don't want unauthenticated user to go that far.. makes sense?
9 years ago
JSF
Hi all,
I am new to JSF and I am working on handling session timeout for a JSF application.
I am trying to get the code to work for ajax calls and not able to achieve that so far. I have tried two approaches:
Approach 1: SessionListener (for cleanup work) and SessionFilter (for filtering every request and checking if session timed out)
My Code snippet of doFilter() of SessionFilter:


Approach 2: CustomeExceptionHandler handling ViewExpiredException
Code snippet of handle() :


Both these approaches work for non-ajax POST calls but not for ajax calls. When I run my app in debug mode, I can step through all the statements for ajax calls also, which gives me an idea that the control does come to my code, executes it but for some reason, nothing happens on the UI.
I have been trying to redirect user to a timeout page but the ideal thing would be to display a JSF dialog and upon hitting 'OK' take user to Home Screen (My app does not have a login screen.)
I can provide more details if needed.
I have a basic questions also, is view expiring exactly same as session timeout?

Any help would be much appreciated, thanks,
Swati.
9 years ago
JSF
Hi all,

I am new to Websphere Server and have this error at server startup, I cannot figure out. I am working on maintenance of a project somebody else made.
I looked into other posts with similar problem, but nothing seems to work for me. Below is the error log I get when I try to publish the project:

[12/5/11 10:25:50:614 EST] 0000000a SystemErr R com.ibm.ws.exception.RuntimeWarning: com.ibm.ws.exception.RuntimeError: com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: ESBAvailableReportJMSRouter.jar
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplications(ApplicationMgrImpl.java:795)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:542)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:820)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:649)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:149)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:820)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:649)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:444)
at com.ibm.ws.runtime.WsServerImpl.bootServerContainer(WsServerImpl.java:187)
at com.ibm.ws.runtime.WsServerImpl.start(WsServerImpl.java:133)
at com.ibm.ws.runtime.WsServerImpl.main(WsServerImpl.java:387)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:53)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.run(WSLauncher.java:219)
at java.lang.Thread.run(Thread.java:571)
Caused by: com.ibm.ws.exception.RuntimeError: com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: ESBAvailableReportJMSRouter.jar
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:942)
at com.ibm.ws.runtime.component.ApplicationMgrImpl$AppInitializer.run(ApplicationMgrImpl.java:2070)
at com.ibm.ws.runtime.component.ComponentImpl$_AsynchInitializer.run(ComponentImpl.java:304)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1475)
Caused by: com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: ESBAvailableReportJMSRouter.jar
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.checkType(ModuleRefImpl.java:492)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.initModuleFileFromEAR(ModuleRefImpl.java:120)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.getModuleFile(ModuleRefImpl.java:98)
at com.ibm.ws.classloader.ClassGraph.addModule(ClassGraph.java:135)
at com.ibm.ws.classloader.ClassLoaderManager.initialize(ClassLoaderManager.java:192)
at com.ibm.ws.classloader.ClassLoaderManager.<init>(ClassLoaderManager.java:155)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:699)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:918)
... 3 more

[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplications(ApplicationMgrImpl.java:795)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:542)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:820)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:649)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:149)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:820)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:649)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:444)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.WsServerImpl.bootServerContainer(WsServerImpl.java:187)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.WsServerImpl.start(WsServerImpl.java:133)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.WsServerImpl.main(WsServerImpl.java:387)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.WsServer.main(WsServer.java:53)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at java.lang.reflect.Method.invoke(Method.java:391)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.bootstrap.WSLauncher.run(WSLauncher.java:219)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at java.lang.Thread.run(Thread.java:571)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R Caused by: com.ibm.ws.exception.RuntimeError: com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: ESBAvailableReportJMSRouter.jar
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:942)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationMgrImpl$AppInitializer.run(ApplicationMgrImpl.java:2070)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ComponentImpl$_AsynchInitializer.run(ComponentImpl.java:304)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1475)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R Caused by: com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: ESBAvailableReportJMSRouter.jar
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.checkType(ModuleRefImpl.java:492)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.initModuleFileFromEAR(ModuleRefImpl.java:120)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.getModuleFile(ModuleRefImpl.java:98)
[12/5/11 10:25:50:614 EST] 0000000a SystemErr R at com.ibm.ws.classloader.ClassGraph.addModule(ClassGraph.java:135)
[12/5/11 10:25:50:630 EST] 0000000a SystemErr R at com.ibm.ws.classloader.ClassLoaderManager.initialize(ClassLoaderManager.java:192)
[12/5/11 10:25:50:630 EST] 0000000a SystemErr R at com.ibm.ws.classloader.ClassLoaderManager.<init>(ClassLoaderManager.java:155)
[12/5/11 10:25:50:630 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:699)
[12/5/11 10:25:50:630 EST] 0000000a SystemErr R at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:918)
[12/5/11 10:25:50:630 EST] 0000000a SystemErr R ... 3 more


If I need to provide more details, please let me know.
Any help / opinion is much appreciated.

Thanks,
Swati.
10 years ago
Congrats a ton!
10 years ago

Mark Spritzler wrote:Which version of Spring are you using? Are you using any OXM Object to XML mapping frameworks like JAXB?


Sorry for not mentioning that earlier. I am using Spring 3.0.5 and JAXB 2.0.

Mark Spritzler wrote:If you are using Spring 3.0 you can just add a few annotations and make it a REST Webservice. And have the client request the return value to be xml.


That's precisely what I would want to do.
I also got the feeling that I do not need to return ModelAndView, but was unable to work out the details. Can you please explain the annotations I need to add to return the XML in a little detail. Thanks much.
10 years ago
Hello,
I am working on a Spring application and I am new to Spring (or any framework). So, pardon me if I sound too naive.
My method annotated with @RequestMapping is responsible for storing the image(s) on server and return back the id generated in XML format. So, the method is got to be POST. I need help in generating the response in XML format. Below is the code I have:

I need the response in XML format:
<files>
<file>
<fname>abc.jpg</fname>
<id>123</id>
</file>
<file>
<fname>xyz.jpg</fname>
<id>456</id>
</file>
</files>

If there are Spring config entries, please tell me that too.
10 years ago
Paul: No problem.

Bear: Thanks for reply. Reading the java docs (File class), I also have the opinion that characters which are allowed by the underlying platform can only be used for filenames. Probably that's why File class provides this method:
public boolean canRead()
Tests whether the application can read the file denoted by this abstract pathname.

Also, I tried Samba Jcifs API (jcifs.smb.SmbFile), as it handles the file system generically, Windows or Unix, but it also failed to read from a folder with special characters, strengthening my opinion.

Thanks all for your time.
10 years ago
Okay.

The application is a simple Java Application, that runs always.
The user I am using, has access to the share. (The app can access a file / folder without any special character).
No, it is not a service. It is a Process.

I am working on fixing a bug where it fails to read only from the files which have incorrect syntax according to Windows.

If you would be kind enough to read the Exception detail I posted twice, it says, "The filename, directory name, or volume label syntax is incorrect" but that is the actual path for my file, just that I created it from Mac.

Makes sense?
10 years ago
I wanted to come up with as much detail as I thought would be necessary.

Well, as I mentioned, when I try accessing the file with ABC_? folder name, I get the following exception:

java.io.FileNotFoundException: \\prod1\cust1\ABC_?\myImage.jpg (The filename, directory name, or volume label syntax is incorrect)

which says the syntax is incorrect. But it happens to be the actual path for the file.
10 years ago