Introduction to JavaScript course. The course was updated in 2014-15.
Will allow you to understand what is JavaScript, what's it history and how you can use it.
The set of slides "Introduction to jQuery" is a follow up - which would allow the reader to have a basic understanding across JavaScript and jQuery.
Introduction to angular with a simple but complete projectJadson Santos
A simple front end project with angular. Its show how to create your first components, include bootstrap templates, create routes and build the project to production.
This session is about Django, which is a web framework build in python. It has several features like admin interface and ORM. The architecture of Django has Model, View, and template and it's ORM saves the pain of writing database queries.
Introduction to JavaScript course. The course was updated in 2014-15.
Will allow you to understand what is JavaScript, what's it history and how you can use it.
The set of slides "Introduction to jQuery" is a follow up - which would allow the reader to have a basic understanding across JavaScript and jQuery.
Introduction to angular with a simple but complete projectJadson Santos
A simple front end project with angular. Its show how to create your first components, include bootstrap templates, create routes and build the project to production.
This session is about Django, which is a web framework build in python. It has several features like admin interface and ORM. The architecture of Django has Model, View, and template and it's ORM saves the pain of writing database queries.
In this comprehensive guide, Angular is described as a one-stop solution for front-end development. Learn everything there is to know about Angular, including how it works, why, and the benefits.
What is the DOM?
The DOM is a W3C (World Wide Web Consortium) standard.
The DOM defines a standard for accessing documents:
"The W3C Document Object Model (DOM) is a platform and language-neutral interface that allows programs and scripts to dynamically access and update the content, structure, and style of a document."
The W3C DOM standard is separated into 3 different parts:
Core DOM - standard model for all document types
XML DOM - standard model for XML documents
HTML DOM - standard model for HTML documents
The HTML DOM (Document Object Model)
When a web page is loaded, the browser creates a Document Object Model of the page.
The HTML DOM model is constructed as a tree of Objects.
With the HTML DOM, JavaScript can access and change all the elements of an HTML document.
In JavaScript, almost "everything" is an object.
-Booleans can be objects (if defined with the new keyword)
-Numbers can be objects (if defined with the new keyword)
-Strings can be objects (if defined with the new keyword)
-Dates are always objects
-Maths are always objects
-Regular expressions are always objects
-Arrays are always objects
-Functions are always objects
-Objects are always objects
JavaOne 2015 : How I Rediscovered My Coding Mojo by Building an IoT/Robotics ...Mark West
Is your project dragging you down? Are you stuck with the same old technologies? Are you bored with coding? If you answer “yes” to any of these questions, you may have lost your coding mojo—just like this session’s speaker did a few years back. Come hear how he learned new technologies and rediscovered his coding mojo by building an IoT/robotics prototype: a voice-controlled robot. Along the way, you’ll hear about HTML5 speech recognition, controlling hardware with Node.js and Johnny-Five, using WebSocket and MQTT for communication between components, and finally how you can easily combine the Raspberry Pi and Arduino platforms to gain ultimate power over your own projects.
In this comprehensive guide, Angular is described as a one-stop solution for front-end development. Learn everything there is to know about Angular, including how it works, why, and the benefits.
What is the DOM?
The DOM is a W3C (World Wide Web Consortium) standard.
The DOM defines a standard for accessing documents:
"The W3C Document Object Model (DOM) is a platform and language-neutral interface that allows programs and scripts to dynamically access and update the content, structure, and style of a document."
The W3C DOM standard is separated into 3 different parts:
Core DOM - standard model for all document types
XML DOM - standard model for XML documents
HTML DOM - standard model for HTML documents
The HTML DOM (Document Object Model)
When a web page is loaded, the browser creates a Document Object Model of the page.
The HTML DOM model is constructed as a tree of Objects.
With the HTML DOM, JavaScript can access and change all the elements of an HTML document.
In JavaScript, almost "everything" is an object.
-Booleans can be objects (if defined with the new keyword)
-Numbers can be objects (if defined with the new keyword)
-Strings can be objects (if defined with the new keyword)
-Dates are always objects
-Maths are always objects
-Regular expressions are always objects
-Arrays are always objects
-Functions are always objects
-Objects are always objects
JavaOne 2015 : How I Rediscovered My Coding Mojo by Building an IoT/Robotics ...Mark West
Is your project dragging you down? Are you stuck with the same old technologies? Are you bored with coding? If you answer “yes” to any of these questions, you may have lost your coding mojo—just like this session’s speaker did a few years back. Come hear how he learned new technologies and rediscovered his coding mojo by building an IoT/robotics prototype: a voice-controlled robot. Along the way, you’ll hear about HTML5 speech recognition, controlling hardware with Node.js and Johnny-Five, using WebSocket and MQTT for communication between components, and finally how you can easily combine the Raspberry Pi and Arduino platforms to gain ultimate power over your own projects.
In this talk I give an overview of IBM's efforts to create a VM-agnostic toolkit of runtime components from the mature J9 Java Virtual Machine (JVM). I provide a summary of the motivations behind this project, talk about some important proof points with CPython and Ruby MRI, describe the motivations behind an open community for this technology, and discuss the many challenges with creating a runtime agnostic Just In Time compiler from the Testarossa Java JIT.
Keynote presentation by IBM Distinguished Engineer and Chief Technology Officer of Java John Duimovich and IBM Vice President of Cloud Platform Development Tim Vanderham at JavaOne 2015.
WebSocket in Enterprise Applications 2015Pavel Bucek
Presentation from JavaOne 2015.
This session, which covers use cases of JSR 356 (Java API for WebSocket) and some features of Oracle’s implementation related to enterprise applications, contains description of standard use cases and recommends optimizations and best practices for using the JSR 356 API. After that, it presents more-complex schemes involving authentication support, fallback support, and clustering.
Overview of web services, SOAP, WSDL and UDDI.
A web service provides a defined set of functionality on a machine-processable interface.
The web service interface is described in a formal language like WSDL that allows creating code to access the service thus simplifying web service consumer (client) and provider (server) development.
In big web services, the interface is typically described in WSDL while the access to the service makes use of the SOAP message protocol.
SOAP has its roots in remote object access but is now a general message based and asynchronous transport mechanism.
SOAP is typically carried in HTTP (HyperText Transmission Protocol), but other message based protocols like SMTP (Email) or plain TCP could be used as well.
WSDL provides a formalized description of an interface that is coarsely separated in an abstract service interface definition containing operations and data types, a transport binding that describes how the web service is accessed and finally a description of the location (address) under which a web service is accessible.
UDDI (Universal Description and Discovery Protocol) was meant to become the standard protocol for some kind of a public yellow pages where publicly accessible web services would be listed. Lack of industry interest, however, prevented UDDI to gain widespread use.
1. Introduction to Web Services
2. Web Service Architecture
3. What are Web Services?
4. Why are Web Services?
5. The base of WS
6. What is SOAP?
7. What is WSDL?
8. How to test a web service?
9. Examples
Communication & presentation skills training course duration 12hrs in 2days , advanced course Video & assignment embedded for mid-level career or management level.
A distributed system is a collection of computational and storage devices connected through a communications network. In this type of system, data, software, and users are distributed.
Business need of IT systems to get integrated. Why legacy systems are feeling modern technologies like SOA can help them to keep alive by providing the integration solution.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
"Impact of front-end architecture on development cost", Viktor TurskyiFwdays
I have heard many times that architecture is not important for the front-end. Also, many times I have seen how developers implement features on the front-end just following the standard rules for a framework and think that this is enough to successfully launch the project, and then the project fails. How to prevent this and what approach to choose? I have launched dozens of complex projects and during the talk we will analyze which approaches have worked for me and which have not.
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Jeffrey Haguewood
Sidekick Solutions uses Bonterra Impact Management (fka Social Solutions Apricot) and automation solutions to integrate data for business workflows.
We believe integration and automation are essential to user experience and the promise of efficient work through technology. Automation is the critical ingredient to realizing that full vision. We develop integration products and services for Bonterra Case Management software to support the deployment of automations for a variety of use cases.
This video focuses on the notifications, alerts, and approval requests using Slack for Bonterra Impact Management. The solutions covered in this webinar can also be deployed for Microsoft Teams.
Interested in deploying notification automations for Bonterra Impact Management? Contact us at sales@sidekicksolutionsllc.com to discuss next steps.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
Let's dive deeper into the world of ODC! Ricardo Alves (OutSystems) will join us to tell all about the new Data Fabric. After that, Sezen de Bruijn (OutSystems) will get into the details on how to best design a sturdy architecture within ODC.
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
3. Overview
General Definition
“Web services are software components that interact with one another
dynamically via standard Internet Technologies, making it possible to build
bridges between IT systems that otherwise would require extensive
development efforts”
-Gartner Group
Web services are
Complementary to existing technology
Building blocks (components) used to construct larger applications
Evolutionary technology: The latest in a long line of approaches for distributed
applications communication
Web services are NOT
A rip and replace technology
A solution to all the integration woes
4. Overview
Key Features
Web services are self-contained.
On the client side, no additional software is required. A programming
language with XML and HTTP client support is enough to get you started.
On the server side, merely a Web server and a SOAP server are required.
Web services are self-describing.
Neither the client nor the server knows or cares about anything besides the
format and content of request and response messages (loosely coupled
application integration).
Web services can be published, located, and invoked across the Web.
This technology uses established lightweight Internet standards such as HTTP.
It leverages the existing infrastructure. Some additional standards that
are required to do so include SOAP, WSDL, and UDDI.
Web services are language-independent and interoperable.
Client and server can be implemented in different environments. Existing
code does not have to be changed in order to be Web service enabled.
Cntd…
5. Overview
Key Features
Web services are inherently open and standard-based.
XML and HTTP are the major technical foundation for Web services. A large part
of the Web service technology has been built using open-source projects.
Therefore, vendor independence and interoperability are realistic goals this
time.
Web services build on proven mature technology
There are a lot of commonalities, as well as a few fundamental differences to
other distributed computing frameworks. For example, Web services are build
with SOA Architecture.
Web services are loosely coupled
Traditionally, application design has depended on tight interconnections at both
ends. Web services require a simpler level of coordination that allows a more
flexible re-configuration for an integration of the services in question.
Web services provide the ability to wrap existing applications
Already existing stand-alone applications can easily be integrated into the
service-oriented architecture by implementing a Web service as an interface.
6. Architecture
Characteristics of the Web service architecture
Webservice that follows the service-oriented architecture employs a
loose coupling betweenthe participants. Such a loose coupling provides
greater flexibility:
In this architecture, a client is not coupled to a server, but to a service.
Thus, the integration of the server to use takes place outside of the scope
of the client application programs.
Functional components and their interfaces are separated. Therefore,
new interfaces can be plugged in more easily.
Within complex applications, the control of business processes can be
isolated. A business rule engine can be incorporated to control the
workflow of a defined business process. Depending on the state of the
workflow, the engine calls the respective services.
Bindings are specified using configuration files and can thus easily be
adapted to new needs.
7. Continue…
Concept of a service-oriented
The service provider creates a Web service and possibly publishes its
interface and access information to the service registry.
The service broker (also known as service registry) is responsible for making
the Web service interface and implementation access information
available to any potential service requestor.
The service requestor locates entries in the broker registry using various find
operations and then binds to the service provider in order to invoke one of
its Web services.
9. Core Technologies
The following are the core technologies used for Web services.
XML (eXtensible Markup Language)
The markup language that underlies most of the specifications used for Web
services. XML is a generic language that can be used to describe any kind of
content in a structured way, separated from its presentation to a specific device.
SOAP (Simple Object Access Protocol)
SOAP similar to JDBC, is a network, transport, and programming language and
platform neutral protocol that allows a client to call a remote service. The message
format is XML.
WSDL (Web services description language)
WSDL is an XML-based interface and implementation description language. The
service provider uses a WSDL document in order to specify the operations a Web
service provides, as well as the parameters and data types of these operations. A
WSDL document also contains the service access information.
UDDI (universal description, discovery, and integration)
UDDI is both a client-side API and a SOAP-based server implementation that can be
used to store and retrieve information on service providers and Web services.
10. WSDL
WSDL architecture
Web Services Description Language (WSDL) files
are written in Extensible Markup Language (XML).
WSDL is one alternative to make service
interfaces and implementations available in the
UDDI registry.
WSDL includes the workflow description (business
process execution language for Web services,
BPEL4WS)
WSDL is the base for SOAP server deployment
and SOAP client generation.
A WSDL file contains the following parts:
Web service interface definition
This is part contains the elements, as
well as the namespaces.
Web service implementation
This part contains the definition of
the service and ports.
The following is the structure of the
information in a WSDL file : A WSDL file
contains the following parts:
11. WSDL Architecture
The following is the structure of the information in a WSDL file : A WSDL file
contains the following parts:
Port Type
Messages
Types
Bindings
Service
Ports
Operation Signatures
Parameter Definitions
Complex Type Definitions
Transport protocol and payload format
Service Definition Element
Supported Interface Bindings
12. Continue…
A WSDL file describes a Web service with the following elements:
portType
The description of the operations and associated messages. The
portType element defines abstract operations.
<portType name="EightBall">
<operation name="getAnswer">
<input message="ebs:IngetAnswerRequest"/>
<output message="ebs:OutgetAnswerResponse"/>
</operation>
</portType>
message
The description of input and output parameters and return values.
<message name="IngetAnswerRequest">
<part name="meth1_inType" type="ebs:questionType"/>
</message>
<message name="OutgetAnswerResponse">
<part name="meth1_outType" type="ebs:answerType"/>
</message>
13. WSDL
types
The schema for describing XML types used in the messages.
<types>
<xsd:schema targetNamespace="...">
<xsd:complexType name="questionType">
<xsd:element name="question" type="string"/> </xsd:complexType>
<xsd:complexType name="answerType">
...
</types>
binding
The bindings describe the protocol that is used to access a portType, as well as the data formats for
the messages that are defined by a particular portType element.
<binding name="EightBallBinding" type="ebs:EightBall"> <soap:binding style="rpc”
transport="schemas.xmlsoap.org/soap/http">
<operation name="ebs:getAnswer">
<soap:operation soapAction="urn:EightBall"/>
<input>
<soap:body
namespace="urn:EightBall" ... />
…
14. WSDL
The services and ports define the location of the Web service
Service
The service contains the Web service name and a list of ports.
Ports
The ports contain the location of the Web service and the
binding used for service access.
<service name="EightBall">
<port binding="ebs:EightBallBinding" name="EightBallPort">
<soap:address
location="localhost:8080/axis/EightBall"/>
</port>
</service>
15. SOAP
SOAP
SOAP is a lightweight protocol intended for exchanging structured information
in a decentralized, distributed environment. SOAP uses XML technologies to
define an extensible messaging framework, which provides a message
construct that can be exchanged over a variety of underlying protocols. The
framework has been designed to be independent of any particular
programming model and other implementation specific semantics.
It represents the main way of communication between the three key actors in
a service oriented architecture (SOA): service provider, service requestor and
service broker. The main goal of its design is to be simple and extensible. A
SOAP message is used to request a Web service.
16. SOAP
SOAP can be used over any transport protocol such as TCP, HTTP, SMTP
This protocol consists of three parts:
An envelope that defines a framework for describing message content and
processing instructions.
A set of encoding rules for expressing instances of application-defined data types.
A convention for representing remote procedure calls and responses.
SOAP is a protocol-independent transport and can be used in combination with a
variety of protocols. In Web services SOAP is used in combination with HTTP, HTTP
extension framework and Java Message Service (JMS).
SOAP is also operating-system independent and not tied to any programming
language or component technology.
As long as the client can issue XML messages, it does not matter what technology
is used to implement the client. Also, both server and client sides can reside on any
suitable platform.
17. SOAP
SOAP Schema:
The Envelope element is always the root element of a SOAP
message. The Envelope element contains an optional Header
element, followed by a mandatory Body element.
The Body element represents the message payload. The Body
element is a generic container in that it can contain any number of
elements from any namespace. This is ultimately where the data
goes that you're trying to send.
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<!-- optional -->
<!-- header blocks go here... -->
</soap:Header>
<soap:Body>
<!-- payload or Fault element goes here... -->
</soap:Body>
</soap:Envelope>
20. UDDI
The Universal Description, Discovery and Integration (UDDI)
define a way to publish and discover information about Web
services. The term “Web service” describes specific business
functionality exposed by a company, usually through an
Internet connection, for the purpose of providing a way for
another company or software program to use the service.
Conceptually, the information provided in a UDDI business
registration consists of three components:
white pages
address, contact, and known identifiers;
yellow pages
industrial categorizations based on standard taxonomies;
green pages
the technical information about services that are exposed by
the business. Green pages include references to specifications
for Web services, as well as support for pointers to various file and
URL based discovery mechanisms if required.
21. Service Styles
Service Styles - RPC, Document, Wrapped, and Message
RPC:
RPC services are the default in Axis
Axis will deserialize XML into Java objects which can be fed to your service, and will
serialize the returned Java object(s) from your service back into XML.
Document
Document services do not use any encoding (so in particular, you won't see multiref
object serialization or SOAP-style arrays on the wire) but DO still do XML<->Java
databinding
Wrapped
Wrapped services are just like document services, except that rather than binding
the entire SOAP body into one big structure, they "unwrap" it into individual
parameters
Message
Message services receive and return arbitrary XML in the SOAP Envelope without
any type mapping / data binding. If you want to work with the raw XML of the
incoming and outgoing SOAP Envelopes, write a message service
D:Program Files
j2sdk_nbnetbeans3.5to
22. Service Styles
<schema targetNamespace="http://commerce.com/PO">
<complexType name="POType">
<sequence>
<element name="item" type="xsd:string"/>
<element name="quantity" type="xsd:int"/>
<element name="description" type="xsd:string"/>
</sequence>
</complexType>
<element name="PurchaseOrder" type="POType"/>
document style service, this would map to a method like this:
public void method(PurchaseOrder po)
In other words, the ENTIRE <PurchaseOrder> element would be handed to your method as a
single bean with three fields inside it. On the other hand,
• wrapped style service, it would map to a method like this:
public void purchaseOrder(String item, int quantity, String description)
Message Service
public Element [] method(Element [] bodies);
public SOAPBodyElement [] method (SOAPBodyElement [] bodies);
public Document method(Document body);
public void method(SOAPEnvelope req, SOAPEnvelope resp);
24. An Example
Axis Setup
Axis software in the form of xml-axis-beta3-bin.zip can be downloaded from
http://archive.apache.org/dist/ws/axis/beta3
Extract the folder from zip file to c:/xml-axis folder
Set “%XML_AXIS% = c:/xml-axis” as environment variable
Set classpath = %XML_AXIS%libaxis.jar; %XML_AXIS% libcommons-logging.jar;
%XML_AXIS%libjaxrpc.jar;c:xml-axisliblog4j-1.2.4.jar; %XML_AXIS%libtt-
bytecode.jar; %XML_AXIS%libwsdl4j.jar;%XML_AXIS%libxmlParserAPIs.jar;
%XML_AXIS%libsaaj.jar %JAVA_HOME%libtools.jar;
Apache Tomcat Setup
Download Apache tomcat (jakarta-tomcat-4.1.31.exe) from
http://mirror.tomato.it/apache/jakarta/tomcat-4/v4.1.31/bin
Set “CATALINA_HOME = C:Apache Tomcat 4.0” as environment variable
Also set “path=%path%;CATALINA_HOMEbin”
Add the following in server.xml (C:Apache Tomcat 4.0conf).
<Context path="/axis" docBase="C:xml-axiswebappsaxis" debug="0"/>
Start tomacat web server
25. An Example
A sample java Class
public class HelloWorld{
public String sayHello(String reader){
System.out.println("Service Called");
return "Hi " + reader + " How are you";
}
}
Steps to Expose as Web Service
Write the following to a text file and name it as HelloWorldService.wsdd.
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns=“http://xml.apache.org/axis/wsdd/” xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="HelloWorldService" provider="java:RPC">
<parameter name="allowedMethods" value=“sayHello"/>
<parameter name="className" value="HelloWorld"/>
</service>
</deployment>
26. An Example
Use the above wsdl file to expose as web service with the following command.
java -classpath "%classpath%;C:jarsaxis.jar;C:jarsjaxrpc.jar;C:jarscommons-
logging-1.0.3.jar;C:jarscommons-discovery-0.2.jar;C:jarsjndi.jar;C:jarssaaj.jar;."
org.apache.axis.client.AdminClient -h localhost -p 8080 -s
WebservicesTest/servlet/AxisServlet "C:HelloWorldService.wsdd“
Test the exposed web service
http://localhost:8080/WebservicesTest/servlet/AxisServlet
Click on “wsdl” to view wsdl file in browser.
Use the following command to generate wsdl file for the exposed service
Java org.apache.axis.wsdl.Java2WSDL HelloWorld -l
http://localhost:8080/WebservicesTest/services/HelloWorldService
Copy the wsdl file to %XML_AXIS% root
Use the following command to generate the stubs for given wsdl file
java org.apache.axis.wsdl.WSDL2Java C:xml-axisHelloWorldService.wsdl
For the generated stubs write a java class to access the web service.
27. An Example
Java code to access the web service via stubs
import java.rmi.RemoteException;
import javax.xml.rpc.ServiceException;
public class HelloWorldStubClient {
public static void main(String[] args) {
try{
//Fetch HelloWorldService object from Service Locator generated
HelloWorldService hWorldService = new HelloWorldServiceLocator();
//Fetch actual service hosted from the service.
HelloWorld hWorld = hWorldService.getHelloWorldService();
//call the Service method
System.out.println(hWorld.sayHello("Harish"));
}catch(ServiceException sExc){
sExc.printStackTrace();
}catch(RemoteException rExc){
rExc.printStackTrace();
}
}
}
29. Documentation
The JAX-WS 2.0 specification demands that the exception annotated with @WebFault must
have two constructors and one method:
WrapperException(String message, FaultBean faultInfo)
WrapperException(String message, FaultBean faultInfo, Throwable cause)
FaultBean getFaultInfo()
The WrapperException is replaced by the name of the exception, and FaultBean is replaced by
the class name that implements the fault bean. The fault bean is a Java bean that contains the
information of the fault and is used by the Web service client to know the cause for the fault.
Sample
@javax.xml.ws.WebFault(name="AddNumbersException",
targetNamespace="http://server.fromjava/jaxws")
public class AddNumbersException_Exception extends Exception {
private fromjava.client.AddNumbersException faultInfo;
public AddNumbersException_Exception(String message, AddNumbersException faultInfo) {
super(message);
this.faultInfo = faultInfo;
}
public AddNumbersException_Exception(String message, AddNumbersException faultInfo,
Throwable cause) {
super(message, cause);
this.faultInfo = faultInfo;
}
public AddNumbersException getFaultInfo() {
return faultInfo;
}
}
31. Documentation
HandlerChain
Example:
Handler Interface
public class LoggingHandler implements
SOAPHandler<SOAPMessageContext>
public boolean handleFault(SOAPMessageContext context)
public boolean handleMessage(SOAPMessageContext context)
public Set<QName> getHeaders()