jasig CAS 实战

官网:

http://www.jasig.org/cas

http://www.jasig.org/cas/public-api 这一页谈到为什么使用final关键字屏蔽了扩展,晕吧!

用户手册: https://wiki.jasig.org/display/CASUM/Home

使用clientfilter https://wiki.jasig.org/display/CASC/Using+CASFilter

获取跟多用户信息: http://www.open-open.com/home/space-124-do-blog-id-791.html

http://www.ibm.com/developerworks/web/library/wa-singlesign/

http://www.iteye.com/topic/544899

 

RESTFull Login: https://wiki.jasig.org/display/CASUM/RESTful+API

这个文档写的不全,增加的maven引用没有完全写出来,为了能让在maven下跑起来,可费了不少功夫。

下面是最终可跑的pom

><?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>edu.university.cas</groupId> <artifactId>cas-server</artifactId> <packaging>war</packaging> <version>1.0-SNAPSHOT</version>

Continue reading jasig CAS 实战

it-e-74 CMS

CMS(Cryptographic Message Syntax) is used to digitally sign or encrypt arbitrary messages. CMS describes an encapsulation syntax for data protection. It supports digital signatures and Encryption. The syntax allows multiple encapsulation, so one encapsulation envelope can be nested inside another. Likewise, one party can digitally sign some previously encapsulated data. It also allows arbitrary attributes, such as signing time, to be authenticated along with the message content, and provides for other attributes such as counter-signatures to be associated with a signature.

arbitrary ['ɑ:bitrəri]

adj. [数] 任意的;武断的;专制的

Continue reading it-e-74 CMS

spring ejb3 jta 事务泛谈

其实我很早就用过spring,当时抱着in action看了好几遍,但是一直没有怎么用。时不时忘记了又跑回去看,我看别人蛮喜欢用spring,但是我就是不喜欢用,主要是我不喜欢xml配置。连hibenate的配置我都不喜欢。

今天回忆一下spring,拿官方指定的文档来说吧.

spring:

http://www.theserverside.com/news/1364527/Introduction-to-the-Spring-Framework [作者是spring的作者]

spring的目的主要是简化j2ee的运用,使用一种pojo的无侵入的编程风格。它整合各种开源框架,是种方便的胶水,也是使用灵活的骨架。

它有以下几个主要方面的功能:

反转控制IOC:

面向接口的编程,松耦合。--不过这也带来了讨厌的配置

jdbc抽象:

jdbc模板

ORM框架整合:

hibernate,ibatis……

面向方面的编程AOP:

由动态代理和cglib实现,提供事务抽象。这个吵得蛮厉害,而我又用的很少,所以不多说。

spring MVC web:

参见http://kazge.com/archives/435.html

实现和使用EJB:

这似乎对ejb2来说的,

使用proxy来包装无状态bean和客户端,得到pojo的便利。加上springbean的便利,可以减少EJB使用的复杂度。

测试:

有spring特点的测试(回滚……)。

事务:

我再谈谈事务,spring里面提供对事务的抽象,其底层可以使用JTA, JDBC, Hibernate, JPA, 和 JDO。这里要搞清楚事务这个概念,在目前java里面,事务还是针对关系数据库据持久化来说的,大部分nosql是不支持事务的,也和jdbc没关系。spring的事物抽象最终是反映到关系数据库上来。

ejb3:

ejb3默认使用容器管理事务CMT,策略为REQUIRED。即每个远程方法必须一个事务。遇到异常会回滚事务,但是@ApplicationException(rollback=false)时则不会回滚。

Continue reading spring ejb3 jta 事务泛谈

it-e-73 Graph plotters

Graph plotters are used to produce high quality precision graphics usually on large sheets
of paper.
They are slow, but can draw continuous curves often in a variety of colours. They are
especially useful for architectural drawings, building plans and
CAD (Computer Aided Design) applications, where precision
drawing is required.
A mechanical arm holds a pen which can be moved
across the page. The paper is sometimes laid on a flat bed
(flat bed plotter) or on a rotating drum (drum plotter).

 

drum [drʌm]

n. 鼓,鼓声

v. 击鼓,作鼓声

Continue reading it-e-73 Graph plotters

it-e-72 Introduction To the Image Compression Manager

The Image Compression Manager provides your application with an interface for compressing
and decompressing images and sequences of images that is independent of devices and algorithms.
Uncompressed image data requires a large amount of storage space. Storing a single
640-by-480 pixel image in 32-bit color can require as much as 1.2 MB. Sequences of images, like
those that might be contained in a QuickTime movie, demand substantially more storage than
single images. This is true even for sequences that consist of fairly small images, because the
movie consists of such a large number of those images. Consequently, minimizing the storage
requirements for image data is an important consideration for any application that works with
images or sequences of images.
The Image Compression Manager allows your application to
use a common interface for all image-compression and image-decompression operations;
take advantage of any compression software or hardware that may be present in a given
Macintosh configuration;
store compressed image data in pictures;
temporarily compress sequences of images, further reducing the storage requirements of
movies;
display compressed PICT files without the need to modify your application;
use an interface that is appropriate for your applicationa high-level interface if you do
not need to manipulate many compression parameters or a low-level interface that
provides you greater control over the compression operation.
The Image Compression Manager compresses images by invoking image compressor components
and decompresses images using image decompressor components. Compressor and decompressor
components are code resources that present a standard interface to the Image Compression Manager and
provide image-compression and image-decompression services, respectively. The Image Compression
Manager receives application requests and coordinates the actions of the appropriate components. The
components perform the actual compression and decompression. Compressor and decompressor
components are standard components and are managed by the Component Manager. For detailed
information about creating compressor and decompressor components, see Inside Macintosh:
QuickTime Components.
Because the Image Compression Manager is independent of specific compression algorithms
and drivers, it provides a number of advantages to developers of image- compression algorithms.
Specifically, compressor and decompressor components can
present a common application interface for software-based compressors and hardware-based
compressors;

provide several different compressors and compression options, allowing the Image
Compression Manager or the application to choose the appropriate tool for a particular
situation.

substantially [səb'stænʃ(ə)li]
ad. 实质上,本质上,大体上

Continue reading it-e-72 Introduction To the Image Compression Manager

it-e-71 Application of Digital Image Processing

The field of digital image processing has experienced continuous and significant expansion
in recent years. The usefulness of this technology is apparent in many different disciplines
covering medicine through remote sensing【遥感】. The advances and wide availability of image
processing hardware has further enhanced the usefulness of image processing.
Remote sensing is the process of collecting data about objects or landscape features without
coming into direct physical contact with them.
Digital Image Processing is not only a step in the remote sensing process, but is itself a
process that consists of several steps. It is important to remember that the ultimate goal of this
process is to extract information from an image that is not readily apparent or is not available in
its original form. The steps taken in processing an image will vary from image to image for

multiple reasons, including the format and initial condition of the image, the information of
interest (i.e., geologic formations vs. land cover), the composition of scene elements. There are
three general steps in processing a digital image; preprocessing, display and enhancement, and
information extraction.
PreprocessingBefore digital images can be analyzed, they usually require some degree of
preprocessing. This may involve radiometric corrections, which attempt to remove the effects of
sensor errors and/or environmental factors.[1] A common method of determining what errors have
been introduced into an image is by modeling the scene at the time of data acquisition using
ancillary data collected.
Geometric corrections are also very common prior to any image analysis. If any types of
area, direction or distance measurements are to be made using an image, it must be rectified if
they are to be accurate.[2] Geometric rectification is a process by which points in an image are
registered to corresponding points on a map or another image that has already been rectified. The
goal of geometric rectification is to put image elements in their proper planimetric (x and y)
positions.
Information EnhancementThere are numerous procedures that can be performed to
enhance an image. However, they can be classified into two major categories: point operations
and local operations. Point operations change the value of each individual pixel independent of
all other pixel, while local operations change the value of individual pixels in the context of the
values of neighboring pixels. Common enhancements include image reduction, image
magnification, transect extraction, contrast adjustments (linear and non-linear), band ratioing,
spatial filtering, fourier transformations, principle components analysis, and texture
transformations.
Information ExtractionUnlike analog image processing, digital image processing
presently relies almost wholly on the primary elements of tone and color of image pixels.
There has been some success with expert systems and neural networks which attempt to
enable the computer to mimic the ways in which humans interpret images. Expert systems
accomplish this through the compilation of a large database of human knowledge gained from
analog image interpretation which the computer draws upon in its interpretations.[3] Neural
networks attempt to "teach" the computer what decisions to make based upon a training data set.
Once it has "learned" how to classify the training data successfully, it is used to interpret and
classify new data sets.
Once the remotely sensed data has been processed, it must be placed into a format that can
effectively transmit the information it was intended to. This can be done in a variety of ways
including a printout of the enhanced image itself, and image map, a thematic map, a spatial
database, summary statistics and/or graphs. Because there are a variety of ways in which the
output can be displayed, a knowledge not only of remote sensing, but of such fields GIS,
cartography, and spatial statistics are a necessity. With an understanding of these areas and how
they interact one with another, it is possible to produce output that give the user the information

needed without confusion. However, without such knowledge it is more probable that output will
be poor and difficult to use properly, thus wasting the time and effort expended in processing the
remotely sensed data.

 

1, ancillary  [æn'siləri]
a. 辅助的
n. 助手

2, rectify  ['rektifai]
v. 订正,矫正,改正

3, planimetric  [,pleinə'metric]
adj. 平面的
4, transect  [træn'sekt, -'zekt-, trɑ:n-]
n. 横断面
vt. 横断;横切
5, mimic  ['mimik]
a. 模仿的,假的
[计算机] 模拟的
6, analog 
n. 类似(模拟量)

Continue reading it-e-71 Application of Digital Image Processing

【转】磁道、柱面、扇区、磁盘簇、寻道时间、旋转延迟、存取时间

http://my.oschina.net/xiangxw/blog/11288

1.磁道

以盘片中心为圆心,用不同的半径,划分出不同的很窄的圆环形区域,称为磁道。

2.柱面

上下一串盘片中,相同半径的磁道所组成的一个圆柱型的环壁,就称为柱面。

3.扇区

磁盘上的每个磁道被等分为若干个弧段,这些弧段便是磁盘的扇区.扇区是磁盘最小的物理存储单元

4.磁盘簇(windows)

windows将相邻的扇区组合在一起,形成一个簇,然后再对簇进行管理

5.寻道时间

磁头从开始移动到移动到数据所在磁道所需要的时间

6.旋转延迟

165952_00Fr_96486

首先,读写头沿径向移动,移到要读取的扇区所在磁道的上方,这段时间称为寻道时间(seek time)。

然后,通过盘片的旋转,使得要读取的扇区转到读写头的下方,这段时间称为旋转延迟时间(rotational latency time)。

例:一个7200(转 /每分钟)的硬盘,每旋转一周所需时间为60×1000÷7200=8.33毫秒,则平均旋转延迟时间为8.33÷2=4.17毫秒(最多旋转1圈,最少不用旋转,平均情况下,需要旋转半圈)。[磁盘是顺时针转的,只会朝一个方向转]

7.存取时间

平均寻道时间与平均旋转延迟时间之和称为平均存取时间(average access time)

Continue reading 【转】磁道、柱面、扇区、磁盘簇、寻道时间、旋转延迟、存取时间

nosql 分类

类型

部分代表

特点

列存储

Hbase

Cassandra

Hypertable

顾名思义,是按列存储数据的。最大的特点是方便存储结构化和半结构化数据,方便做数据压缩,对针对某一列或者某几列的查询有非常大的IO优势。

文档存储

MongoDB

CouchDB

文档存储一般用类似json的格式存储,存储的内容是文档型的。这样也就有有机会对某些字段建立索引,实现关系数据库的某些功能。

key-value存储

Tokyo Cabinet / Tyrant

Berkeley DB

MemcacheDB

Redis

Riak

可以通过key快速查询到其value。一般来说,存储不管value的格式,照单全收。(Redis包含了其他功能)

图存储

Neo4J

FlockDB

图形关系的最佳存储。使用传统关系数据库来解决的话性能低下,而且设计使用不方便。

对象存储

db4o

Versant

通过类似面向对象语言的语法操作数据库,通过对象的方式存取数据。

xml数据库

Berkeley DB XML

BaseX

高效的存储XML数据,并支持XML的内部查询语法,比如XQuery,Xpath。

板桥的分类:http://www.jdon.com/jivejdon/thread/38312

>NoSQL数据库异军突起,随着Digg和 sf.net大型应用不断采取NoSQL,NoSQL运动已经蓬勃发展,NoSQL数据库很多,如何对他们分类,以便方便地根据自己应用特色选择不同的NoSQL数据库呢?

Continue reading nosql 分类

Pagination


Total views.

© 2013 - 2019. All rights reserved.

Powered by Hydejack v6.6.1