Referenced file contain errors in STS - mysql

I setup an environment STS 4,0 and import a project. In Web-INF folder it gives such error:
Referenced file contains errors (http://www.ibm.com/webservices/xsd/j2ee_web_services_client_1_1.xsd). For more information,
right click on the message in the Problems View and select "Show Details..."`
It gives the error in the first line.
How to get rid of it...
I am frustrated.
I tried to install "/npm run build" but not successful.
<?xml version="1.0" encoding="UTF-8" ?>
<taglib xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-jsptaglibrary_2_0.xsd"
version="2.0">

Related

Generating liquibase xml file from current database

I have tried to create liquibase XML existing from MySQL database. My goal is to generate liquibase XML schema from MySQL database.
Any way to achieve this solution.
I have already tried with dropwizard command
java -jar myjar-4.1.0.jar --changeLogFile="generate.xml" --diffTypes="data" generateChangeLog
but it does not work for me.
After trying so many time finally I got my solution.
Follow following steps to generate migration from existing MySQL database.
Add initial migrations.xml into the project with below lines.
<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.0.xsd">
</databaseChangeLog>
Run: above migration with "db migrate" for dropwizard, it'll create databaseChangeLog and databaseChangeLogLock tables into Database.
Run Following command as per requirement.
Command Syntax :
liquibase --driver=com.mysql.jdbc.Driver --classpath=[path to db driver jar] --changeLogFile=[Path to above migration.xml] --url=[Database URL] --username=[Username] --password=[Password] [command parameters]
U can refer this link or link for above common parameter
Note:
Command require [path to DB driver jar], JDBC.jar file for this if you don't have.

Error while deploying cas-overlay 4.2.4 on weblogic 12c server

I am trying to deploy the cas-overlay 4.2.4 on weblogic 12c server and got the below error.
Any idea ?
Error logs
weblogic.Deployer invoked with options: -noexit -adminurl t3://localhost:7001 -user weblogic -redeploy -name cas-4.2.4 -source C:\Project_Gitlab\cas-overlay-template\target/cas.war -targets AdminServer -upload
<17-Aug-2016 10:05:09 o'clock BST> <Info> <J2EE Deployment SPI> <BEA-260121> <Initiating redeploy operation for application, cas-4.2.4 [archive: C:\Project_Gitlab\cas-overlay-template\target\cas.war], to AdminServer .>
Task 2 initiated: [Deployer:149026]deploy application cas-4.2.4 on AdminServer.
Task 2 failed: [Deployer:149026]deploy application cas-4.2.4 on AdminServer.
Target state: redeploy failed on Server AdminServer
weblogic.descriptor.DescriptorException: VALIDATION PROBLEMS WERE FOUND
<231:11> problem: cvc-complex-type.2.4a: Expected element 'tracking-mode#http://xmlns.jcp.org/xml/ns/javaee' instead of 'cookie-config#http://xmlns.jcp.org/xml/ns/javaee' here in element session-config#http://xmlns.jcp.org/xml/ns/javaee
Update:-
web.xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0">
<display-name>Central Authentication System (CAS)</display-name>
.......
<session-config>
<!-- Default to 5 minute session timeouts -->
<session-timeout>5</session-timeout>
<tracking-mode>COOKIE</tracking-mode>
<cookie-config>
<http-only>true</http-only>
</cookie-config>
</session-config>

Security Error Loading Local Xml File

This was working fine the last time I tried it a few days ago, but I am getting a strange error now. I have Xamp running with this file in htdocs call YAM.xml:
<?xml version="1.0" encoding="utf-8"?>
<VAST version="2.0">
<Ad id="TEST">
<InLine>
<AdSystem version="3.1">Test</AdSystem>
<AdTitle>JVAM Test</AdTitle>
<Impression></Impression>
<Creatives>
<Creative sequence="1">
<Linear>
<Duration>00:00:15</Duration>
<MediaFiles>
<MediaFile delivery="progressive" width="640" height="480" scalable="1" type="video/mp4">
<![CDATA[http://127.0.0.1/YAM.swf?someVar=123344&vastUrl=http://127.0.0.1/Yashi200_15sec.mp4&vastUrl=http%3A%2F%2Fad4.liverail.com%2F%3FLR_PUBLISHER_ID%3D1331%26LR_SCHEMA%3Dvast2-vpaid&domainName=developers.google.com&fallbackVastUrl=http%3A%2F%2Fad4.liverail.com%2F%3FLR_PUBLISHER_ID%3D1331%26LR_SCHEMA%3Dvast2]]>
</MediaFile>
</MediaFiles>
<VideoClicks>
<VideoClick>
<ClickThrough>
<![CDATA[http://www.cats.com]]>
</ClickThrough>
</VideoClick>
</VideoClicks>
</Linear>
</Creative>
</Creatives>
</InLine>
</Ad>
</VAST>
Also, my crossdomain.xml looks like this:
<?xml version="1.0" ?>
<cross-domain-policy>
<site-control permitted-cross-domain-policies="master-only"/>
<allow-access-from domain="*" secure="false"/>
<allow-http-request-headers-from domain="*" headers="*"/>
</cross-domain-policy>
I'm entering the path to this VAST xml (http://127.0.0.1/YAM.xml) into a VAST validator in the browser like the one here: http://zutils.zedo.com/vastvalidator/
For some reason when I try test the ad it gives this error:
* Security Sandbox Violation * Connection to tmp/ Warning: file_get_contents(http://127.0.0.1/YAM.xml): failed
to open stream: HTTP request failed! HTTP/1.0 500 Internal Server
Error in
/home/adwww/apache/htdocs/adwww/vastvalidator/createxmlfile.php
on line 3 zedoxml144583131.xml halted - not permitted
from
http://zutils.zedo.com/vastvalidator/ova.jwplayer.5x/dist/swf/5.9.swf
Error #2044: Unhandled error:. text=Task Queue failed at step 0: Error
2048: Security sandbox violation: http://zutils.zedo.com/vastvalidator/ova.jwplayer.5x/dist/swf/5.9.swf
cannot load data from tmp/ Warning:
file_get_contents(http://127.0.0.1/YAM.xml): failed to open stream:
HTTP request failed! HTTP/1.0 500 Internal Server Error in
/home/adwww/apache/htdocs/adwww/vastvalidator/createxmlfile.php
on line 3 zedoxml144583131.xml.
The local server is running, and if I put http://127.0.0.1/YAM.xml into my address bar I see the xml file.
I have been banging my head against the wall for a few days so if someone sees the problem please help. thanks.
127.0.0.1 is localhost, the server cannot reach you (your file) through that IP.

Fatal Error :3:2: The markup in the document following the root element must be well-formed. When trying to run web app

First time i've got this error. I have no idea what happened but it seems to say something about my context.xml file.
Here is the error from tomcat
[Fatal Error] :3:2: The markup in the document following the root element must be well-formed.
C:\Users\Nyco.tony-PC\Documents\NetBeansProjects\Apo\nbproject\build-impl.xml:724:
Deployment error:
Tomcat configuration file C:\Users\Nyco.tony-PC\Documents\NetBeansProjects\Apo\web\META- INF\context.xml seems to be broken. Please make sure it is parseable and valid.
See the server log for details.
at org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment.deploy(Deployment.java:232)
at org.netbeans.modules.j2ee.ant.Deploy.execute(Deploy.java:106)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
at sun.reflect.GeneratedMethodAccessor313.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:390)
at org.apache.tools.ant.Target.performTasks(Target.java:411)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:284)
at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:539)
at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:153)
Caused by: org.netbeans.modules.j2ee.deployment.common.api.ConfigurationException: Tomcat configuration file C:\Users\Nyco.tony-PC\Documents\NetBeansProjects\Apo\web\META-INF\context.xml seems to be broken. Please make sure it is parseable and valid.
at org.netbeans.modules.tomcat5.config.TomcatModuleConfiguration.getContext(TomcatModuleConfiguration.java:176)
at org.netbeans.modules.tomcat5.config.TomcatModuleConfiguration.getDatasources(TomcatModuleConfiguration.java:201)
at org.netbeans.modules.j2ee.deployment.config.ConfigSupportImpl.getDatasources(ConfigSupportImpl.java:398)
at org.netbeans.modules.j2ee.deployment.impl.DeploymentHelper.deployJdbcDrivers(DeploymentHelper.java:87)
at org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment.deploy(Deployment.java:180)
... 16 more
Caused by: java.lang.RuntimeException: DOM graph creation failed: org.netbeans.modules.schema2beans.Schema2BeansRuntimeException: Failed to create the XML-DOM Document. Check your XML to make sure it is correct.
The markup in the document following the root element must be well-formed.
at org.netbeans.modules.tomcat5.config.gen.Context.createGraph(Context.java:3178)
at org.netbeans.modules.tomcat5.config.gen.Context.createGraph(Context.java:3162)
at org.netbeans.modules.tomcat5.config.TomcatModuleConfiguration.getContext(TomcatModuleConfiguration.java:169)
... 20 more
and to think that I only have 3 lines on my context.xml file
<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" path="/Apo"/>
<Resource auth="Container" driverClassName="com.mysql.jdbc.Driver" maxActive="100" maxIdle="30" maxWait="10000" name="jdbc/apo" password="user" type="javax.sql.DataSource" url="jdbc:mysql://localhost:3306/apo" username="myUser"/>
Try placing the Resource tag inside the Context tag, e.g.:
<Context antiJARLocking="true" path="/Apo">
<Resource auth="Container" .../>
</Context>

Adobe Air - Update not compatible error

I'm trying to update an AIR 2.5 app. (Packed as Windows .exe)
This error pops up bei updating:
Application namespace and update descriptor namespace are not
compatible
My .xml file:
<?xml version="1.0" encoding="utf-8"?>
<update xmlns="http://ns.adobe.com/air/framework/update/description/1.0">
<version>1.1</version>
<url>http://www.example.com/updater/my-app.exe</url>
<description><![CDATA[New version
]]></description>
</update>
Can somebody tell my what I did wrong?
Thanks
Uli
A bit has changed since AIR 2.5. Mainly, change version to versionNumber, and add versionLabel. Here is an example from: http://www.adobe.com/devnet/air/articles/air_update_framework.html
<?xml version="1.0" encoding="utf-8"?>
<update xmlns="http://ns.adobe.com/air/framework/update/description/2.5">
<versionNumber>0.9.2</versionNumber>
<versionLabel>Beta 2</versionLabel>
<url>http://localhost/updater/AIRUpdater.air</url>
<description><![CDATA[
This version has fixes for the following knowns issues:
*First issue
*Second issue
]]></description>
</update>
Not you are wrong, you cannot use the updater IF you package your application with native installer.
Documentation here : http://help.adobe.com/fr_FR/FlashPlatform/reference/actionscript/3/flash/desktop/Updater.html